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

`skipAfterFailureCount` not working with JUnit 5

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.22.1
    • None
    • JUnit 5.x support
    • None
    • java version "1.8.0_201"
      Java(TM) SE Runtime Environment (build 1.8.0_201-b09)
      Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)

      macOS 10.14.3

      Apache Maven 3.6.0

    Description

      Attached MVP demonstrating issue. 2 commits. One showing working example with JUnit 4.12, and another showing reproducing issue with JUnit 5.4. There are 3 failing tests and skipAfterFailureCount=1 configured.

      Steps to reproduce

      1. Run $ mvn clean test on attached project

      Expected

      After fail1() test method fails, the other two test methods not executed.

      Actual

      All 3 methods executed:

      [INFO] Results:
      [INFO]
      [ERROR] Failures:
      [ERROR]   MyTest.fail1:12
      [ERROR]   MyTest.fail2:17
      [ERROR]   MyTest.fail3:22

       

      Attachments

        1. stop-on-fail.zip
          39 kB
          Ion Iovu

        Activity

          People

            Unassigned Unassigned
            iovuio Ion Iovu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: