Uploaded image for project: 'Maven Surefire'
  1. Maven Surefire
  2. SUREFIRE-1681

Don't ignore errors while using maven.test.failure.ignore

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.0.0-M3
    • Fix Version/s: None
    • Component/s: Maven Surefire Plugin
    • Labels:
      None

      Description

      This is a follow up for SUREFIRE-1426.

      Surefire should only ignore test failures when SurefirePlugin.testFailureIgnore property is set to true (as the name suggests). Test errors should not be ignored.

      If the forked JVM crashes during the test, thenĀ TEST-*.xml report file is not created, so the user will miss the problem when he evaluates test reports afterward (e.g. in Jenkins).

      The code of SurefireHelper.report execution could beĀ improved to verify the error count:

      if ( reportParameters.isTestFailureIgnore() && result.getErrors() == 0 )
      {
          log.error( createErrorMessage( reportParameters, result, firstForkException ) );
      }
      

      instead of simply ignoring all problems as it's now:

      if ( reportParameters.isTestFailureIgnore() )
      {
          log.error( createErrorMessage( reportParameters, result, firstForkException ) );
      }
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                tibordigana Tibor Digana
                Reporter:
                kwart Josef Cacek
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 10m
                  10m