You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ti...@apache.org on 2016/09/03 22:35:22 UTC

[04/14] maven-surefire git commit: SHOW_ERRORS should be observed before thrown exception on Enum.valueOf()

SHOW_ERRORS should be observed before thrown exception on Enum.valueOf()


Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/8da7eda3
Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/8da7eda3
Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/8da7eda3

Branch: refs/heads/master
Commit: 8da7eda3152a2dd56065c01cdb1fee15aff38736
Parents: dd6b620
Author: Tibor17 <ti...@lycos.com>
Authored: Fri Aug 26 14:37:22 2016 +0200
Committer: Tibor17 <ti...@lycos.com>
Committed: Fri Aug 26 14:37:22 2016 +0200

----------------------------------------------------------------------
 .../org/apache/maven/plugin/surefire/SurefireHelper.java  | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/8da7eda3/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java
----------------------------------------------------------------------
diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java
index 3b0bbc2..8952787 100644
--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java
+++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java
@@ -127,17 +127,17 @@ public final class SurefireHelper
             Method getRequestMethod = session.getClass().getMethod( "getRequest" );
             MavenExecutionRequest request = (MavenExecutionRequest) getRequestMethod.invoke( session );
 
+            if ( request.isShowErrors() )
+            {
+                cli.add( SHOW_ERRORS );
+            }
+
             String f = getFailureBehavior( request );
             if ( f != null )
             {
                 // compatible with enums Maven 3.0
                 cli.add( CommandLineOption.valueOf( f.startsWith( "REACTOR_" ) ? f : "REACTOR_" + f ) );
             }
-
-            if ( request.isShowErrors() )
-            {
-                cli.add( SHOW_ERRORS );
-            }
         }
         catch ( Exception e )
         {