You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Brett Porter (JIRA)" <ji...@codehaus.org> on 2007/01/21 22:49:17 UTC
[jira] Updated: (SUREFIRE-73) Surefire fails to start when the
local repository and the project (pom.xml) lives in different window drives
[ http://jira.codehaus.org/browse/SUREFIRE-73?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brett Porter updated SUREFIRE-73:
---------------------------------
Affects Version/s: 1.5.2 (2.1.2 plugin)
Fix Version/s: 2.0 (2.2 plugin)
> Surefire fails to start when the local repository and the project (pom.xml) lives in different window drives
> ------------------------------------------------------------------------------------------------------------
>
> Key: SUREFIRE-73
> URL: http://jira.codehaus.org/browse/SUREFIRE-73
> Project: Maven Surefire
> Issue Type: Bug
> Affects Versions: 1.5.2 (2.1.2 plugin)
> Environment: Windows XP
> Java 1.5.0_06
> Maven 2.0.1
> Surefire fork mode: once
> Reporter: Martin Desruisseaux
> Assigned To: fabrizio giustina
> Fix For: 2.0 (2.2 plugin)
>
>
> We have the following situation:
> - Local repository in {{C:\Documents and Settings\user\.m2}}
> - A Maven 2 project in {{P:\MyProject}}.
> - Surefire fork mode set to "once".
> In this configuration, surefire fails with this (somewhat misleading) error message:
> {quote}
> Setting reports dir: {{P:\MyProject\target/surefire-reports}}
> BUILD ERROR
> There are some test failure.
> {quote}
> This message is misleading because it suggests that some user's tests failed, while actually Surefile didn't executed a single one. It even failed before to create the {{surefire-reports}} directory! So we have no indication about the cause, and printing the stack trace with the {{-e}} option doesn't help much (I suspect that this is because the stack trace was actually produced by a different virtual machine instance, and was not passed to the JVM running Maven). Running Maven with the {{-X}} option provides more hints however. We can see that Maven try to executes the following command:
> {{java -Xmx512M -enableassertions -classpath "C:\...snip...\.m2\repository\org\apache\maven\surefire\surefire-booter\1.5.2\surefire-booter-1.5.2.jar; C:\Java\Apache\Maven2\bin\..\core\plexus-utils-1.0.5.jar" org.apache.maven.surefire.SurefireBooter P:\MyProject}}
> Running this command manually gives the following output:
> {code}
> ClassLoader: typeclass sun.misc.Launcher$ExtClassLoader, value=...snip...
> : file:/C:/Java/1.5/jre/lib/ext/sunjce_provider.jar
> : file:/C:/Java/1.5/jre/lib/ext/sunpkcs11.jar
> (...snip...)
> ClassLoader: typeclass sun.misc.Launcher$AppClassLoader, value=...snip...
> : file:/C:/Documents ...snip... /.m2/repository/ ...snip.. ./surefire-booter-1.5.2.jar
> : file:/C:/Java/Apache/Maven2/core/plexus-utils-1.0.5.jar
> ClassLoader: typeclass org.apache.maven.surefire.IsolatedClassLoader, value=...snip...
> : file:/P:/MyProjects/
> (...snip...)
> : file:/P:/Documents and Settings/user/.m2/repository/...snip.../surefire-1.5.2.jar
> Exception in thread "main" java.lang.ClassNotFoundException: org.apache.maven.surefire.Surefire
> at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> (...snip...)
> {code}
> As you can see, the path for {{surefire-1.5.2.jar}} wrongly refer to the drive letter {{P:}}. It should be {{C:}} instead.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira