Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 2.12
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Maven 3.0.4, surefire 2.12, JUnit 4.10, JDK1.6_30, WinXP

      Description

      We have a big issue with surefire 2.12 (using default configuration, which means forkMode=once): the Junit tests of the first module pass perfectly, then we have a "Z,0,BYE!" in the log and the surefire plugin fails with:

      The forked VM terminated without saying properly goodbye. VM crash or System.exit called ?
              at org.apache.maven.plugin.surefire.booterclient.output.ForkClient.close(ForkClient.java:244)
      

      It seems related to the following code, taken from maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/booter/ForkedBooter.java:

       runSuitesInProcess( testSet, testClassLoader, startupConfiguration, providerConfiguration );
       // Say bye.
       System.out.println("Z,0,BYE!");
       System.out.flush();
       // noinspection CallToSystemExit
       System.exit( 0 );
      

      This happens at every run, just reverting surefire to 2.11 fixes the issue. If I use forkMode=never, it works, but our code needs a forked VM, otherwise we have SecurityManager issues.

      The surefire configuration itself is very basic:

      <plugin>
      	<groupId>org.apache.maven.plugins</groupId>
      	<artifactId>maven-surefire-plugin</artifactId>
      	<version>2.12</version>
      	<configuration>
      		<argLine>-Xms128m -Xmx1024m</argLine>
      		<includes>
      			<include>**/SelfHostingTests.java</include>
      		</includes>
      	</configuration>
      </plugin>
      

      Attached is the full build log with -X.

        Activity

        Mark Thomas made changes -
        Workflow jira [ 12965955 ] Default workflow, editable Closed status [ 13003675 ]
        Mark Thomas made changes -
        Project Import Mon Apr 06 01:36:33 UTC 2015 [ 1428284193036 ]
        Mark Thomas made changes -
        Workflow jira [ 12728082 ] Default workflow, editable Closed status [ 12759174 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 13:23:32 UTC 2015 [ 1428240212200 ]
        François LEIBER made changes -
        Attachment surefire2.12.log [ 58867 ]
        Kristian Rosenvold made changes -
        Field Original Value New Value
        Assignee Kristian Rosenvold [ krosenvold ]
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Duplicate [ 3 ]
        François LEIBER created issue -

          People

          • Assignee:
            Kristian Rosenvold
            Reporter:
            François LEIBER
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development