Missing:----------1) org.testng:guice:jar:2.0Try downloading the file manually from the project website.Then, install it using the command:mvn install:install-file -DgroupId=org.testng -DartifactId=guice -Dversion=2.0 -Dpackaging=jar -Dfile=/path/to/fileAlternatively, if you host your own repository you can deploy the file there:mvn deploy:deploy-file -DgroupId=org.testng -DartifactId=guice -Dversion=2.0 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
--
You received this message because you are subscribed to the Google Groups "testng-dev" group.
To post to this group, send email to testn...@googlegroups.com.
To unsubscribe from this group, send email to testng-dev+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/testng-dev?hl=en.
<dependency>
<groupId>org.testng</groupId>
<artifactId>guice</artifactId>
<version>2.0</version>
<scope>system</scope>
<systemPath>/Users/cbeust/java/testng/target/checkout/lib-supplied/guice-2.0.jar</systemPath>
</dependency>
<dependency>~Owen
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>2.0</version>
</dependency>
Cédric,
If you take a look at the POM published in central, it already has the path evaluated.:
(from http://repo1.maven.org/maven2/org/testng/testng/5.14.5/testng-5.14.5.pom)
<dependency>
<groupId>org.testng</groupId><artifactId>guice</artifactId>
<version>2.0</version>
<scope>system</scope>
<systemPath>/Users/cbeust/java/testng/target/checkout/lib-supplied/guice-2.0.jar</systemPath>
</dependency>
My guess is that Maven's complaint is that the system path specified doesn't exist on my system. That would also explain the differing behaviors.
Is there any reason you can use the following dependency instead?
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>2.0</version>
</dependency>
If so, it might be possible to instruct maven to use "any version
between 2.0 (including) and 3.1 (excluding)" as follows:
<version>[2.0,3.0)</version>
For details of the version specification syntax, see [1].
This way, the TestNG users could define a specific guice version in
their project's pom (let's say they specify 2.0), and maven would
satisfy the TestNG dependency with the same version (since the maven
coordinates only differ in version numbers, maven knows that its the
same artifact, and will select *one* version of it)
Kind regards
Ansgar
[1]
http://www.sonatype.com/books/mvnref-book/reference/pom-relationships-sect-version-ranges.html
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>[2.0,3.1)</version>
<optional>true</optional>
</dependency>
Users wishing to use guice would have to declare an explicit dependency
on guice in their project's pom. If they don't, they won't have guice in
the classpath (neither will TestNG), and cannot use any of the guice
features of TestNG.
Kind regards
Ansgar
Wait - so this means that TestNG will use Guice 2 regardless of if I tell my project to include Guice 3?
--
Cédric
What is the driving reason behind the change from 5.14.2 to 5.14.3?
Specifically, the guice dependency changing from guice 2.0 transitive (5.14.2) to no dependency and the resulting failure of any testng run with
org.apache.maven.surefire.booter.SurefireExecutionException: org/testng/guice/Module; nested exception is java.lang.NoClassDefFoundError: org/testng/guice/Module
java.lang.NoClassDefFoundError: org/testng/guice/Module
--
You received this message because you are subscribed to the Google Groups "testng-dev" group.
To post to this group, send email to testn...@googlegroups.com.
To unsubscribe from this group, send email to testng-dev+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/testng-dev?hl=en.