diff options
author | Lars Grefer <eclipse@larsgrefer.de> | 2020-08-13 23:21:11 +0200 |
---|---|---|
committer | Lars Grefer <eclipse@larsgrefer.de> | 2020-08-13 23:21:11 +0200 |
commit | d7ba05ce26dd8f72c1d0695ece2cb03d035e3cf9 (patch) | |
tree | b0ca80a1154a73ca8ed1d5d4cf175c2682af6fce /tests/src/test/java/org/aspectj/systemtest/ajc150 | |
parent | 4f027bd94fe71756894f13a4a82123eda4f28b98 (diff) | |
download | aspectj-d7ba05ce26dd8f72c1d0695ece2cb03d035e3cf9.tar.gz aspectj-d7ba05ce26dd8f72c1d0695ece2cb03d035e3cf9.zip |
Remove checks for old Java Versions
Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
Diffstat (limited to 'tests/src/test/java/org/aspectj/systemtest/ajc150')
-rw-r--r-- | tests/src/test/java/org/aspectj/systemtest/ajc150/Ajc150Tests.java | 20 | ||||
-rw-r--r-- | tests/src/test/java/org/aspectj/systemtest/ajc150/GenericsTests.java | 5 |
2 files changed, 8 insertions, 17 deletions
diff --git a/tests/src/test/java/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/test/java/org/aspectj/systemtest/ajc150/Ajc150Tests.java index 8dcb8c34d..62e96d0df 100644 --- a/tests/src/test/java/org/aspectj/systemtest/ajc150/Ajc150Tests.java +++ b/tests/src/test/java/org/aspectj/systemtest/ajc150/Ajc150Tests.java @@ -406,14 +406,12 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { public void testBadASMforEnums() throws IOException { runTest("bad asm for enums"); - if (LangUtil.is15VMOrGreater()) { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - PrintWriter pw = new PrintWriter(baos); - AsmManager.dumptree(pw, AsmManager.lastActiveStructureModel.getHierarchy().getRoot(), 0); - pw.flush(); - String tree = baos.toString(); - assertTrue("Expected 'Red [enumvalue]' somewhere in here:" + tree, tree.contains("Red [enumvalue]")); - } + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + PrintWriter pw = new PrintWriter(baos); + AsmManager.dumptree(pw, AsmManager.lastActiveStructureModel.getHierarchy().getRoot(), 0); + pw.flush(); + String tree = baos.toString(); + assertTrue("Expected 'Red [enumvalue]' somewhere in here:" + tree, tree.contains("Red [enumvalue]")); } public void npeOnTypeNotFound() { @@ -840,11 +838,7 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { } public void testJava5SpecificFeaturesUsedAtJava14OrLower() { - if (LangUtil.is17VMOrGreater()) { - runTest("java 5 pointcuts and declares at pre-java 5 compliance levels - 1.7"); - } else { - runTest("java 5 pointcuts and declares at pre-java 5 compliance levels"); - } + runTest("java 5 pointcuts and declares at pre-java 5 compliance levels - 1.7"); } public void testAnonymousTypes() { diff --git a/tests/src/test/java/org/aspectj/systemtest/ajc150/GenericsTests.java b/tests/src/test/java/org/aspectj/systemtest/ajc150/GenericsTests.java index 76c956965..95ab500fc 100644 --- a/tests/src/test/java/org/aspectj/systemtest/ajc150/GenericsTests.java +++ b/tests/src/test/java/org/aspectj/systemtest/ajc150/GenericsTests.java @@ -922,10 +922,7 @@ public class GenericsTests extends XMLBasedAjcTestCase { */ public static boolean isBridge(java.lang.reflect.Method m) { // why not importing java.lang.reflect.Method? No BCEL clash? - if (!LangUtil.is15VMOrGreater()) { - return false; - } - try { + try { final Class<?>[] noparms = new Class[0]; java.lang.reflect.Method isBridge = java.lang.reflect.Method.class.getMethod("isBridge", noparms); |