From b9474d5ca841efebd356d1823927b29f0cb03e2b Mon Sep 17 00:00:00 2001 From: aclement Date: Thu, 5 May 2005 08:28:54 +0000 Subject: Can check vm level now. --- .../testsrc/org/aspectj/tools/ajc/AjcTestCase.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/org.aspectj.ajdt.core/testsrc/org/aspectj/tools/ajc/AjcTestCase.java b/org.aspectj.ajdt.core/testsrc/org/aspectj/tools/ajc/AjcTestCase.java index 02a5028c4..a3311ef1b 100644 --- a/org.aspectj.ajdt.core/testsrc/org/aspectj/tools/ajc/AjcTestCase.java +++ b/org.aspectj.ajdt.core/testsrc/org/aspectj/tools/ajc/AjcTestCase.java @@ -52,6 +52,19 @@ public class AjcTestCase extends TestCase { private RunResult lastRunResult; + protected static boolean is13VMOrGreater = true; + protected static boolean is14VMOrGreater = true; + protected static boolean is15VMOrGreater = false; + + static { + String vm = System.getProperty("java.vm.version"); + if (vm.startsWith("1.3")) { + is14VMOrGreater = false; + } else if (vm.startsWith("1.5")) { + is15VMOrGreater = true; + } + } + /** * The Ajc (compiler) instance used for thet test. Created afresh * during the test setup. -- cgit v1.2.3