Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
2.3.1
-
None
-
Windows, Sun JDK 1.5 u10, environment variables include: "JAVA_HOME = C:\Program Files\Java\jdk1_5"
Description
When the JAVA_HOME environment variable includes spaces, surefire-reports execution failes to locate java
Partial error below, full error in context is available in attachment.
Forking command line: "C:\Program Files\Java\jdk1.5.0_10\jre\bin\java" -classpath [...]
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] There are test failures.
[INFO] ------------------------------------------------------------------------
This is similar to behavior the gwt-maven plugin experienced a little while back,
http://groups.google.com/group/gwt-maven/browse_thread/thread/b8ccf7896b0f65f0/df999ee333246567%23df999ee333246567
WORKAROUNDS:
Either changing JAVA_HOME to not use spaces
such as "c:\progra~1\java\jdk1_5"
Explicitly use a previous version of the maven-surefire-plugin
such as
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.3</version>
</plugin>