From d0f6be9886afaee6080cd4b7cd5d165c767b71f0 Mon Sep 17 00:00:00 2001 From: Benedikt Ritter Date: Sun, 25 Sep 2016 19:50:48 +0200 Subject: [PATCH] Fix test for IS_JAVA_XX constants. The test would never check anything, since it tested against the java.specification.name property, which has the value "Java Platform API Specification" --- src/test/java/org/apache/commons/lang3/SystemUtilsTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java b/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java index 9b614426c..428beda3e 100644 --- a/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java +++ b/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java @@ -94,7 +94,7 @@ public void testGetUserHome() { @Test @SuppressWarnings("deprecation") public void testIS_JAVA() { - final String javaVersion = System.getProperty("java.specification.name"); + final String javaVersion = SystemUtils.JAVA_VERSION; if (javaVersion == null) { assertFalse(SystemUtils.IS_JAVA_1_1); assertFalse(SystemUtils.IS_JAVA_1_2);