Skip to content
This repository has been archived by the owner. It is now read-only.
Browse files
8247741: Test test/hotspot/jtreg/runtime/7162488/TestUnrecognizedVmOp…
… fails when -XX:+IgnoreUnrecognizedVMOptions is set

Use createJavaProcessBuilder() to prevent JTreg flags from being passed to the new process created by the test

Reviewed-by: lfoltan, dholmes
  • Loading branch information
Harold Seigel committed Jul 1, 2020
1 parent 13b7c2e commit eb78035d0521fcc20f9ac781b7dba12f8269a41c
Showing 1 changed file with 2 additions and 2 deletions.
@@ -35,8 +35,8 @@ public class TestUnrecognizedVmOption {
static final String OPTION="this_is_not_an_option";

public static void main(String[] args) throws Exception {
ProcessBuilder pb =
ProcessTools.createTestJvm("-showversion", "-XX:" + OPTION);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(
"-showversion", "-XX:" + OPTION);
new OutputAnalyzer(pb.start())
.shouldContain("Unrecognized VM option")

0 comments on commit eb78035

Please sign in to comment.