Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
2.10
-
None
-
None
Description
When running a test that contains an ErrorCollector, test failures are not correct when an errorcollector contains failures. For example:
public class ExampleTest { @Rule public ErrorCollector errorCollector = new ErrorCollector(); @Test public void testWithErrorCollector() { errorCollector.checkThat(true, is(false)); errorCollector.checkThat(3, is(4)); } }
Surefire will reports 2 tests run (of which all failed). However, when you fix the same test so that no checks fail, Surefire will report 1 test run.
This is incorrect, as this will result in false information in systems like Hudson or Sonar, the number of testcase should not fluctuate. Surefire should only report 1 test run, as that reflects the actual situation.
Attachments
Issue Links
- Blocked
-
SUREFIRE-841 Incorrect Test Run Count
- Closed
- is duplicated by
-
SUREFIRE-1172 Incompatibility with MultipleFailureException
- Closed
- relates to
-
SUREFIRE-841 Incorrect Test Run Count
- Closed