summaryrefslogtreecommitdiffstats
path: root/testing/src
diff options
context:
space:
mode:
authorwisberg <wisberg>2004-10-05 20:51:24 +0000
committerwisberg <wisberg>2004-10-05 20:51:24 +0000
commit90d3f9f305bc825480c4f9504b3eb635ce5e903c (patch)
tree4cab806b28b4548935eea0fe154b7944df0b3a8a /testing/src
parent615f09f359cc692f3f476defcf1badd8596086b0 (diff)
downloadaspectj-90d3f9f305bc825480c4f9504b3eb635ce5e903c.tar.gz
aspectj-90d3f9f305bc825480c4f9504b3eb635ce5e903c.zip
support vm args during forking (simple update: forking still requires system properties)
Diffstat (limited to 'testing/src')
-rw-r--r--testing/src/org/aspectj/testing/harness/bridge/JavaRun.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/testing/src/org/aspectj/testing/harness/bridge/JavaRun.java b/testing/src/org/aspectj/testing/harness/bridge/JavaRun.java
index 21a67986c..e0ce0a799 100644
--- a/testing/src/org/aspectj/testing/harness/bridge/JavaRun.java
+++ b/testing/src/org/aspectj/testing/harness/bridge/JavaRun.java
@@ -42,17 +42,20 @@ import java.util.*;
public class JavaRun implements IAjcRun {
public static String FORK_KEY = "javarun.fork";
public static String JAVA_KEY = "javarun.java";
+ public static String VM_ARGS_KEY = "javarun.vmargs";
public static String JAVA_HOME_KEY = "javarun.java.home";
public static String BOOTCLASSPATH_KEY = "javarun.bootclasspath";
private static final boolean FORK;
private static final String JAVA;
private static final String JAVA_HOME;
+ private static final String VM_ARGS;
static final String BOOTCLASSPATH;
static {
FORK = (null != getProperty(FORK_KEY));
JAVA = getProperty(JAVA_KEY);
JAVA_HOME = getProperty(JAVA_HOME_KEY);
BOOTCLASSPATH = getProperty(BOOTCLASSPATH_KEY);
+ VM_ARGS = getProperty(VM_ARGS_KEY);
try {
System.setSecurityManager(RunSecurityManager.ME);
} catch (Throwable t) {
@@ -228,6 +231,12 @@ public class JavaRun implements IAjcRun {
java = jfile.getAbsolutePath();
}
cmd.add(java);
+ if (null != VM_ARGS) {
+ String[] args = XMLWriter.unflattenList(VM_ARGS);
+ for (int i = 0; i < args.length; i++) {
+ cmd.add(args[i]);
+ }
+ }
cmd.add("-classpath");
cmd.add(classpath);
cmd.add(spec.className);