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 2020/05/21 20:05:41 UTC
[maven-surefire] branch master updated: recommended exclusion of
j11 in Surefire1570ModularFailsafeIT - see similar issue
https://issues.apache.org/jira/browse/MJAVADOC-610
This is an automated email from the ASF dual-hosted git repository.
tibordigana pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git
The following commit(s) were added to refs/heads/master by this push:
new 263759b recommended exclusion of j11 in Surefire1570ModularFailsafeIT - see similar issue https://issues.apache.org/jira/browse/MJAVADOC-610
263759b is described below
commit 263759b709ac2ac9a7bd86d65cfd63b6955d66be
Author: tibordigana <ti...@apache.org>
AuthorDate: Thu May 21 22:05:14 2020 +0200
recommended exclusion of j11 in Surefire1570ModularFailsafeIT - see similar issue https://issues.apache.org/jira/browse/MJAVADOC-610
---
.../apache/maven/surefire/its/fixture/HelperAssertions.java | 13 +++++++++----
.../surefire/its/jiras/Surefire1570ModularFailsafeIT.java | 2 ++
2 files changed, 11 insertions(+), 4 deletions(-)
diff --git a/surefire-its/src/test/java/org/apache/maven/surefire/its/fixture/HelperAssertions.java b/surefire-its/src/test/java/org/apache/maven/surefire/its/fixture/HelperAssertions.java
index 7f7aa69..27f671b 100644
--- a/surefire-its/src/test/java/org/apache/maven/surefire/its/fixture/HelperAssertions.java
+++ b/surefire-its/src/test/java/org/apache/maven/surefire/its/fixture/HelperAssertions.java
@@ -29,6 +29,7 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
+import static java.lang.Double.parseDouble;
import static junit.framework.Assert.assertEquals;
import static junit.framework.Assert.assertFalse;
import static junit.framework.Assert.assertTrue;
@@ -180,15 +181,19 @@ public final class HelperAssertions
public static void assumeJavaVersion( double expectedVersion )
{
String thisVersion = System.getProperty( "java.specification.version" );
- assumeTrue( "java.specification.version: " + thisVersion,
- Double.parseDouble( thisVersion ) >= expectedVersion );
+ assumeTrue( "java.specification.version: " + thisVersion, parseDouble( thisVersion ) >= expectedVersion );
}
public static void assumeJavaMaxVersion( double expectedMaxVersion )
{
String thisVersion = System.getProperty( "java.specification.version" );
- assumeTrue( "java.specification.version: " + thisVersion,
- Double.parseDouble( thisVersion ) <= expectedMaxVersion );
+ assumeTrue( "java.specification.version: " + thisVersion, parseDouble( thisVersion ) <= expectedMaxVersion );
+ }
+
+ public static void assumeJavaVersionExcluded( double excludedVersion )
+ {
+ String thisVersion = System.getProperty( "java.specification.version" );
+ assumeTrue( "java.specification.version: " + thisVersion, parseDouble( thisVersion ) != excludedVersion );
}
public static String convertUnicodeToUTF8( String unicode )
diff --git a/surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/Surefire1570ModularFailsafeIT.java b/surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/Surefire1570ModularFailsafeIT.java
index 83d3d08..eb1ff06 100644
--- a/surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/Surefire1570ModularFailsafeIT.java
+++ b/surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/Surefire1570ModularFailsafeIT.java
@@ -24,6 +24,7 @@ import org.junit.Before;
import org.junit.Test;
import static org.apache.maven.surefire.its.fixture.HelperAssertions.assumeJavaVersion;
+import static org.apache.maven.surefire.its.fixture.HelperAssertions.assumeJavaVersionExcluded;
import static org.hamcrest.Matchers.containsString;
import static org.hamcrest.Matchers.is;
@@ -39,6 +40,7 @@ public class Surefire1570ModularFailsafeIT
public void setUp()
{
assumeJavaVersion( 9d );
+ assumeJavaVersionExcluded( 11d );
}
@Test