Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-8415

M2 and M3 builds behave differently when tests fail

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • maven-plugin
    • None
    • Hudson 1.392

      When running our build with goals and options "-U -fae clean install", Maven 2.2.1 and Maven 3.0.1 gives different results when we have test failures:

      Maven 2: Build is executed to end as expected and reported as 'Unstable'.
      Maven 3: Build is stopped immediately after first test failure as 'Failed'.

          [JENKINS-8415] M2 and M3 builds behave differently when tests fail

          Olivier Lamy added a comment -

          I have some trouble to reproduce this.
          Is it a multimodule build ?

          Olivier Lamy added a comment - I have some trouble to reproduce this. Is it a multimodule build ?

          mpe added a comment -

          Yes, it's a multimodule build with several modules. I'll try to find some more facts (and test with 1.393).

          mpe added a comment - Yes, it's a multimodule build with several modules. I'll try to find some more facts (and test with 1.393).

          Olivier Lamy added a comment -

          Ok I know what to fix. (similar to JENKINS-8362 regarding the cause : incompatibility in maven 3).
          Current workaround is to add -Dmaven.test.failure.ignore=true

          Olivier Lamy added a comment - Ok I know what to fix. (similar to JENKINS-8362 regarding the cause : incompatibility in maven 3). Current workaround is to add -Dmaven.test.failure.ignore=true

          mpe added a comment -

          Ok, great!

          mpe added a comment - Ok, great!

          Olivier Lamy added a comment -

          Olivier Lamy added a comment - fixed https://github.com/hudson/hudson/commit/3f2ab68b248a8104053227b074221937f7ab3176 If you have time to test I have pushed a build here http://people.apache.org/~olamy/hudson/main-maven3-support/ Will be in 1.395

          dogfood added a comment -

          Integrated in hudson_main_trunk #440
          JENKINS-8415 M2 and M3 builds behave differently when tests fail
          update changelog for JENKINS-8415

          Olivier Lamy :
          Files :

          • maven-plugin/src/main/java/hudson/maven/reporters/SurefireArchiver.java
          • test/src/test/resources/hudson/maven/maven-multimodule-unit-failure.zip
          • test/src/test/java/hudson/maven/MavenBuildSurefireFailedTest.java

          Olivier Lamy :
          Files :

          • changelog.html

          dogfood added a comment - Integrated in hudson_main_trunk #440 JENKINS-8415 M2 and M3 builds behave differently when tests fail update changelog for JENKINS-8415 Olivier Lamy : Files : maven-plugin/src/main/java/hudson/maven/reporters/SurefireArchiver.java test/src/test/resources/hudson/maven/maven-multimodule-unit-failure.zip test/src/test/java/hudson/maven/MavenBuildSurefireFailedTest.java Olivier Lamy : Files : changelog.html

            olamy Olivier Lamy
            mpe mpe
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: