Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.8, 2.11
-
None
-
linux/windows/maven 2.2.1
-
Patch
Description
from trawling around in the junit code, it appears that a 'legal' displayName for a test org.junit.runner.Description takes the format:
<anyText>(className)
This is created by the method Description.createTestDescription(Class<?> clazz, String name, Annotation... annotations).
JunitParams creates names in the format:
<parameterText> (<methodName>)(className)
and the PARENS regex in JUnit4RunListener doesn't parse this correctly, so fails to find the className. If surefire is run in parallel mode this bombs the ConcurrentReporterManager with an NPE. This stops all subsequent tests from being reported correctly.
There are some changes in SUREFIRE-800 which may stop the NPE from ConcurrentReporterManager, but I've attached a patch to make the PARENS regex just search for the contents of the last pair of braces.