> -----Original Message-----
> From: Dan Fabulich [mailto:
dan@...]
> Sent: 18 February 2008 22:23
> To: Maven Users List
> Subject: RE: Surefire 2.4.1 classpath order
> [snip]
> Looks like we'll need to try some more debugging. :-)
>
> 1) If you run mvn -X you'll see lots of useful debugging
> information, including the command line we used to launch
> Surefire. It looks something like this:
>
> Forking command line: cmd.exe /X /C
> '"C:\jdk1.5.0_12\jre\bin\java -jar
> C:\DOCUME~1\dan\LOCALS~1\Temp\surefirebooter61534.jar
> C:\DOCUME~1\dan\LOCALS~1\Temp\surefire61532tmp
> C:\DOCUME~1\dan\LOCALS~1\Temp\surefire61533tmp"'
>
> You may notice that none of your jars appear on this list;
> that's by design. Go take a look at the jar file and you'll
> see that it's a "manifest-only" jar; it contains only a
> META-INF/MANIFEST.MF file, specifying a Main-Class and a
> Class-Path to run the code. Make sure that the manifest
> looks correct and that the jars/dirs appear in the correct order.
I get
Forking command line: cmd.exe /X /C '""c:\Program Files\Java\jdk1.5.0_14\jre\bin\java" -jar c:\DOCUME~1\benl\LOCALS~1\Temp\surefirebooter53271.jar c:\DOCUME~1\benl\LOCALS~1\Temp\surefire53269tmp c:\DOCUME~1\benl\LOCALS~1\Temp\surefire53270tmp"'
The MANIFEST.MF in the jar shows:
Class-Path: file:/C:/Documents%20and%20Settings/benl/.m2/repository/org/apache/maven/surefire/surefirebooter/2.4.1/surefire-booter-2.4.1.jar file:/C:/Documents%20and%20Settings/benl/.m2/repository/org/apache/maven/surefire/surefire-api/2.4.1/surefire-api-2.4.1.jar file:/C:/Documents%20and%20Settings/benl/.m2/repository/junit/junit/4.2/junit-4.2.jar [snip] file:/c:/Development/Projects/Inuk/MyProject/target/classes/ file:/c:/Development/Projects/Inuk/MyProject/target/test-classes/
Main-Class: org.apache.maven.surefire.booter.SurefireBooter
And in one of the tmp files included
classPathUrl.41=c\:\\Development\\Projects\\Inuk\\MyProject\\target\\test-classes
classPathUrl.40=c\:\\Development\\Projects\\Inuk\\MyProject\\target\\classes
Which when ordered in ascending order would put target/classes before target/test-classes
The effective-pom shows
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.4.1</version>
<configuration>
<redirectTestOutputToFile>true</redirectTestOutputToFile>
<childDelegation>true</childDelegation>
<systemProperties>
<property>
<name>log4j.configuration</name>
<value>log4j.xml</value>
</property>
</systemProperties>
</configuration>
</plugin>
Weird.
Ben
This e-mail is confidential and intended solely for the use of the individual(s) to whom it is addressed. Any views or opinions expressed are those of the author. If you are not the intended recipient, please be advised that any use, dissemination, printing or copying of this email is strictly prohibited.
---------------------------------------------------------------------
To unsubscribe, e-mail:
users-unsubscribe@...
For additional commands, e-mail:
users-help@...