diff options
author | Andy Clement <aclement@pivotal.io> | 2016-06-27 15:49:09 -0700 |
---|---|---|
committer | Andy Clement <aclement@pivotal.io> | 2016-06-27 15:49:09 -0700 |
commit | 92a9d99937725875881b691085fdbf3332917f6e (patch) | |
tree | cff91eca5a63f1db790fc02244db48b2cbf747d4 /ajde.core | |
parent | fa03c791aeb9a4d16c9f0d87e2fe6702e08e0411 (diff) | |
download | aspectj-92a9d99937725875881b691085fdbf3332917f6e.tar.gz aspectj-92a9d99937725875881b691085fdbf3332917f6e.zip |
Fix classpath for tests on Java9
Diffstat (limited to 'ajde.core')
-rw-r--r-- | ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java b/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java index c3a46c047..2265014f9 100644 --- a/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java +++ b/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java @@ -22,6 +22,7 @@ import java.util.Set; import org.aspectj.tools.ajc.AjcTests; import org.aspectj.util.FileUtil; +import org.aspectj.util.LangUtil; /** * Test implementation of ICompilerConfiguration. Allows users to configure the settings via setter methods. By default returns null @@ -58,8 +59,15 @@ public class TestCompilerConfiguration implements ICompilerConfiguration { } public String getClasspath() { - return projectPath + File.pathSeparator + System.getProperty("sun.boot.class.path") + File.pathSeparator - + AjcTests.aspectjrtClasspath(); + StringBuilder classpath = new StringBuilder(); + classpath.append(projectPath); + if (LangUtil.is19VMOrGreater()) { + classpath.append(File.pathSeparator).append(LangUtil.getJrtFsFilePath()); + } else { + classpath.append(File.pathSeparator).append(System.getProperty("sun.boot.class.path")); + } + classpath.append(File.pathSeparator).append(AjcTests.aspectjrtClasspath()); + return classpath.toString(); } public Set<File> getInpath() { |