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



##########
File path: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java
##########
@@ -142,7 +142,10 @@ public static void reportExecution( 
SurefireReportParameters reportParameters, R
                                         PluginConsoleLogger log, Exception 
firstForkException )
         throws MojoFailureException, MojoExecutionException
     {
-        if ( firstForkException == null && !result.isTimeout() && 
result.isErrorFree() )
+        boolean isError = firstForkException != null || result.isTimeout() || 
!result.isErrorFree();
+        boolean isFlaky = reportParameters.getFailOnFlakeCount() > 0
+            && result.getFlakes() >= reportParameters.getFailOnFlakeCount();

Review comment:
       @paplorinc 
   I think `result.getFlakes() >= reportParameters.getFailOnFlakeCount()` is 
okay because it is a condition saying `variable >= constant` and we are 
"watching" variable and not the constant. In maths is the same as you say but 
it is another wording in the sentence.




----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to