Tibor17 commented on a change in pull request #452:
URL: https://github.com/apache/maven-surefire/pull/452#discussion_r794516311



##########
File path: 
surefire-api/src/main/java/org/apache/maven/surefire/api/report/LegacyPojoStackTraceWriter.java
##########
@@ -81,10 +79,15 @@ public String smartTrimmedStackTrace()
         result.append( "#" );
         result.append( testMethod );
         SafeThrowable throwable = getThrowable();
+        final String excClassName = throwable.getTarget().getClass().getName();
         if ( throwable.getTarget() instanceof AssertionError )
+        if ( throwable.getTarget() instanceof AssertionError
+                || "junit.framework.AssertionFailedError".equals( excClassName 
)
+                || "junit.framework.ComparisonFailure".equals( excClassName )
+                || excClassName.startsWith( "org.opentest4j." ) )
         {
             result.append( " " );
-            result.append( getTruncatedMessage( throwable.getMessage(), 
MAX_LINE_LENGTH - result.length() ) );
+            result.append( throwable.getMessage() );

Review comment:
       See the previous code.
   Why you did not see `null` in the console log?
   You are missing the null check here!




-- 
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.

To unsubscribe, e-mail: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to