57
58 static void checkNoContains(TestResult tr, String str) {
59 if (tr.contains(str)) {
60 System.out.println(tr.status);
61 throw new RuntimeException(str + " found");
62 }
63 }
64
65 private static final String VM_SETTINGS = "VM settings:";
66 private static final String PROP_SETTINGS = "Property settings:";
67 private static final String LOCALE_SETTINGS = "Locale settings:";
68
69 static void containsAllOptions(TestResult tr) {
70 checkContains(tr, VM_SETTINGS);
71 checkContains(tr, PROP_SETTINGS);
72 checkContains(tr, LOCALE_SETTINGS);
73 }
74
75 static void runTestOptionDefault() throws IOException {
76 String stackSize = "256"; // in kb
77 if (getArch().equals("ppc64")) {
78 stackSize = "800";
79 }
80 TestResult tr = null;
81 tr = doExec(javaCmd, "-Xms64m", "-Xmx512m",
82 "-Xss" + stackSize + "k", "-XshowSettings", "-jar", testJar.getAbsolutePath());
83 containsAllOptions(tr);
84 if (!tr.isOK()) {
85 System.out.println(tr.status);
86 throw new RuntimeException("test fails");
87 }
88 tr = doExec(javaCmd, "-Xms65536k", "-Xmx712m",
89 "-Xss" + stackSize + "000", "-XshowSettings", "-jar", testJar.getAbsolutePath());
90 containsAllOptions(tr);
91 if (!tr.isOK()) {
92 System.out.println(tr.status);
93 throw new RuntimeException("test fails");
94 }
95 }
96
97 static void runTestOptionAll() throws IOException {
|
57
58 static void checkNoContains(TestResult tr, String str) {
59 if (tr.contains(str)) {
60 System.out.println(tr.status);
61 throw new RuntimeException(str + " found");
62 }
63 }
64
65 private static final String VM_SETTINGS = "VM settings:";
66 private static final String PROP_SETTINGS = "Property settings:";
67 private static final String LOCALE_SETTINGS = "Locale settings:";
68
69 static void containsAllOptions(TestResult tr) {
70 checkContains(tr, VM_SETTINGS);
71 checkContains(tr, PROP_SETTINGS);
72 checkContains(tr, LOCALE_SETTINGS);
73 }
74
75 static void runTestOptionDefault() throws IOException {
76 String stackSize = "256"; // in kb
77 if (getArch().equals("ppc64") || getArch().equals("ppc64le")) {
78 stackSize = "800";
79 }
80 TestResult tr = null;
81 tr = doExec(javaCmd, "-Xms64m", "-Xmx512m",
82 "-Xss" + stackSize + "k", "-XshowSettings", "-jar", testJar.getAbsolutePath());
83 containsAllOptions(tr);
84 if (!tr.isOK()) {
85 System.out.println(tr.status);
86 throw new RuntimeException("test fails");
87 }
88 tr = doExec(javaCmd, "-Xms65536k", "-Xmx712m",
89 "-Xss" + stackSize + "000", "-XshowSettings", "-jar", testJar.getAbsolutePath());
90 containsAllOptions(tr);
91 if (!tr.isOK()) {
92 System.out.println(tr.status);
93 throw new RuntimeException("test fails");
94 }
95 }
96
97 static void runTestOptionAll() throws IOException {
|