Christian Stein created SUREFIRE-1643:
-----------------------------------------

             Summary: JUnit 5 in parallel execution mode confused Surefire 
reports
                 Key: SUREFIRE-1643
                 URL: https://issues.apache.org/jira/browse/SUREFIRE-1643
             Project: Maven Surefire
          Issue Type: Bug
          Components: JUnit 5.x support
    Affects Versions: 3.0.0-M3
            Reporter: Christian Stein


Hi I hope somebody here can help me out. I am observing something strange while 
using JUNIT 5 parallel execution. I have two test classes TagTests, and 
TagTypeTests. When I set the execution mode to CONCURRENT on both classes, and 
run them, the test report shows the test cases on the wrong test class. For 
example, the test case testA belongs to class TagTests, but it is shown in the 
TagTypeTests test report. TagTests has 11 test cases, and TagType has 13 test 
cases. But the test report shows there are 22 test cases in TagTypeTests, and 2 
in TagTests. Is this a known issue of parallelism? How to get around the issue?

Sam Brannen @sbrannen Mar 01 18:00
How is the test report generated? In an IDE? Using a build tool?

James Zhou @jazhou Mar 01 19:47
@sbrannen I am using maven surefire plugin(ver 3.0.0-M3) to run the tests. Here 
is the results:
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.42 s - 
in org.aaa.test.functional.tests.TagCrudTests
[INFO] Tests run: 23, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.148 s 
- in org.aaa.test.functional.tests.TagTypeTests
[INFO] Results:
[INFO]
[INFO] Tests run: 24, Failures: 0, Errors: 0, Skipped: 0
@sbrannen there are actually 11 tests under TagCrudTests. Somehow only one test 
is shown in the report generated by surefire plugin

Christian Stein @sormuras Mar 01 20:31
@jazhou Do you have a minimal (failing) example project to share?

James Zhou @jazhou Mar 01 22:56
@sormuras Sure. Here is the code: https://github.com/jazhou/junit5-parallel-test



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to