提交 9ac37a29 编写于 作者: D dcubed

Merge

...@@ -33,17 +33,17 @@ import com.oracle.java.testlibrary.*; ...@@ -33,17 +33,17 @@ import com.oracle.java.testlibrary.*;
public class BooleanFlagWithInvalidValue { public class BooleanFlagWithInvalidValue {
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(
"-XX:+UseLargePages=8", "-version"); "-XX:+PrintWarnings=8", "-version");
OutputAnalyzer output = new OutputAnalyzer(pb.start()); OutputAnalyzer output = new OutputAnalyzer(pb.start());
output.shouldContain("Improperly specified VM option 'UseLargePages=8'"); output.shouldContain("Improperly specified VM option 'PrintWarnings=8'");
output.shouldHaveExitValue(1); output.shouldHaveExitValue(1);
pb = ProcessTools.createJavaProcessBuilder( pb = ProcessTools.createJavaProcessBuilder(
"-XX:-UseLargePages=8", "-version"); "-XX:-PrintWarnings=8", "-version");
output = new OutputAnalyzer(pb.start()); output = new OutputAnalyzer(pb.start());
output.shouldContain("Improperly specified VM option 'UseLargePages=8'"); output.shouldContain("Improperly specified VM option 'PrintWarnings=8'");
output.shouldHaveExitValue(1); output.shouldHaveExitValue(1);
} }
} }
...@@ -33,10 +33,10 @@ import com.oracle.java.testlibrary.*; ...@@ -33,10 +33,10 @@ import com.oracle.java.testlibrary.*;
public class FlagWithInvalidValue { public class FlagWithInvalidValue {
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(
"-XX:ObjectAlignmentInBytes=v", "-version"); "-XX:MaxRAMFraction=v", "-version");
OutputAnalyzer output = new OutputAnalyzer(pb.start()); OutputAnalyzer output = new OutputAnalyzer(pb.start());
output.shouldContain("Improperly specified VM option 'ObjectAlignmentInBytes=v'"); output.shouldContain("Improperly specified VM option 'MaxRAMFraction=v'");
output.shouldHaveExitValue(1); output.shouldHaveExitValue(1);
} }
} }
...@@ -33,17 +33,17 @@ import com.oracle.java.testlibrary.*; ...@@ -33,17 +33,17 @@ import com.oracle.java.testlibrary.*;
public class NonBooleanFlagWithInvalidBooleanPrefix { public class NonBooleanFlagWithInvalidBooleanPrefix {
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(
"-XX:-ObjectAlignmentInBytes=16", "-version"); "-XX:-MaxRAMFraction=16", "-version");
OutputAnalyzer output = new OutputAnalyzer(pb.start()); OutputAnalyzer output = new OutputAnalyzer(pb.start());
output.shouldContain("Unexpected +/- setting in VM option 'ObjectAlignmentInBytes=16'"); output.shouldContain("Unexpected +/- setting in VM option 'MaxRAMFraction=16'");
output.shouldHaveExitValue(1); output.shouldHaveExitValue(1);
pb = ProcessTools.createJavaProcessBuilder( pb = ProcessTools.createJavaProcessBuilder(
"-XX:+ObjectAlignmentInBytes=16", "-version"); "-XX:+MaxRAMFraction=16", "-version");
output = new OutputAnalyzer(pb.start()); output = new OutputAnalyzer(pb.start());
output.shouldContain("Unexpected +/- setting in VM option 'ObjectAlignmentInBytes=16'"); output.shouldContain("Unexpected +/- setting in VM option 'MaxRAMFraction=16'");
output.shouldHaveExitValue(1); output.shouldHaveExitValue(1);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册