Tibor17 commented on a change in pull request #281: [SUREFIRE-1766] Surefire
does not display TestNG data provider values on command line
URL: https://github.com/apache/maven-surefire/pull/281#discussion_r401106966
##########
File path:
surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/TestNGReporter.java
##########
@@ -183,4 +183,21 @@ public void onConfigurationSuccess( ITestResult result )
//onTestSuccess( result );
}
+ /**
+ * Acquire a better representation of the test name that includes
parameters and the invocation count, if there are
+ * any parameters
+ *
+ * @param result the test result to extract from
+ * @return a descriptive name for the test
+ */
+ private static String testName( ITestResult result )
+ {
+ Object[] parameters = result.getParameters();
+ if ( parameters == null || parameters.length == 0 )
+ {
+ return result.getName();
+ }
+ return result.getName() + Arrays.toString(
Review comment:
Here are the values of `parameters`. It may be unreadable with complext
`toString() value` on the HTML report. In JUnit5 we do not put values but the
types (simple class names from method - not values). Anyway, the Java is
strictly static and so the types identify the unique method signature.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services