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 2015/12/15 08:31:37 UTC

maven-surefire git commit: [SUREFIRE] fixed build

Repository: maven-surefire
Updated Branches:
  refs/heads/master 2261bcea6 -> 436898788


[SUREFIRE] fixed build


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

Branch: refs/heads/master
Commit: 4368987881c7742079363622450f05dc46487ce5
Parents: 2261bce
Author: Tibor17 <ti...@lycos.com>
Authored: Tue Dec 15 08:31:18 2015 +0100
Committer: Tibor17 <ti...@lycos.com>
Committed: Tue Dec 15 08:31:18 2015 +0100

----------------------------------------------------------------------
 .../its/CheckTestNgListenerReporterIT.java      | 32 ++++++++++++--------
 1 file changed, 20 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/43689878/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/CheckTestNgListenerReporterIT.java
----------------------------------------------------------------------
diff --git a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/CheckTestNgListenerReporterIT.java b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/CheckTestNgListenerReporterIT.java
index 3558bce..73c7723 100644
--- a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/CheckTestNgListenerReporterIT.java
+++ b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/CheckTestNgListenerReporterIT.java
@@ -27,6 +27,9 @@ import org.junit.runners.Parameterized;
 import java.util.Arrays;
 import java.util.Collection;
 
+import static org.hamcrest.Matchers.is;
+import static org.hamcrest.Matchers.greaterThanOrEqualTo;
+import static org.junit.Assume.assumeThat;
 import static org.junit.runners.Parameterized.Parameter;
 import static org.junit.runners.Parameterized.Parameters;
 
@@ -44,41 +47,46 @@ public class CheckTestNgListenerReporterIT
     public static Collection<Object[]> data()
     {
         return Arrays.asList(new Object[][] {
-            { "5.6" }, // First TestNG version with reporter support
-            { "5.7" }, // default version from pom of the test case
-            { "5.10" },
-            { "5.13" }, // "reporterslist" param becomes String instead of List<ReporterConfig>
+            { "5.6", "1.5" }, // First TestNG version with reporter support
+            { "5.7", "1.5" }, // default version from pom of the test case
+            { "5.10", "1.5" },
+            { "5.13", "1.5" }, // "reporterslist" param becomes String instead of List<ReporterConfig>
                         // "listener" param becomes String instead of List<Class>
 
                 // configure(Map) in 5.14.1 and 5.14.2 is transforming List<Class> into a String with a space as separator.
                 // Then configure(CommandLineArgs) splits this String into a List<String> with , or ; as separator => fail.
                 // If we used configure(CommandLineArgs), we would not have the problem with white spaces.
-            //{ "5.14.1" }, // "listener" param becomes List instead of String
+            //{ "5.14.1", "1.5" }, // "listener" param becomes List instead of String
                             // Fails: Issue with 5.14.1 and 5.14.2 => join with <space>, split with ","
                             // TODO will work with "configure(CommandLineArgs)"
-            //{ "5.14.2" }, // ReporterConfig is not available
+            //{ "5.14.2", "1.5" }, // ReporterConfig is not available
 
-            //{ "5.14.3" }, // TestNG uses "reporter" instead of "reporterslist"
+            //{ "5.14.3", "1.5" }, // TestNG uses "reporter" instead of "reporterslist"
                           // Both String or List are possible for "listener"
                           // Fails: not able to test due to system dependency org.testng:guice missed the path and use to break CI
                           // ClassNotFoundException: com.beust.jcommander.ParameterException
 
-            //{ "5.14.4" }, { "5.14.5" }, // Fails: not able to test due to system dependency org.testng:guice missed the path and use to break CI
+            //{ "5.14.4", "1.5" }, { "5.14.5", "1.5" }, // Fails: not able to test due to system dependency org.testng:guice missed the path and use to break CI
                                         // ClassNotFoundException: com.beust.jcommander.ParameterException
 
-            { "5.14.6" }, // Usage of org.testng:guice removed
-            { "5.14.9" }, // Latest 5.14.x TestNG version
-            { "6.0" },
-            { "6.9.9" } // Currently latest TestNG version
+            { "5.14.6", "1.5" }, // Usage of org.testng:guice removed
+            { "5.14.9", "1.5" }, // Latest 5.14.x TestNG version
+            { "6.0", "1.5" },
+            { "6.9.9", "1.8" } // Currently latest TestNG version
         });
     }
 
     @Parameter
     public String version;
 
+    @Parameter(1)
+    public String javaVersion;
+
     @Test
     public void testNgListenerReporter()
     {
+
+        assumeThat( System.getProperty( "java.version" ), is( greaterThanOrEqualTo( javaVersion ) ) );
         unpack( "testng-listener-reporter", "_" + version )
                 .resetInitialGoals( version )
                 .executeTest()