Skip to content

Commit

Permalink
[fix] GraalOSRLockTest: Move ManagementFactory availability check to …
Browse files Browse the repository at this point in the history
…beforeclass.
  • Loading branch information
davleopo authored and dougxc committed Oct 31, 2017
1 parent c110f39 commit 8b83703
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,16 +56,13 @@ public class GraalOSRLockTest extends GraalOSRTestBase {
private static boolean TestInSeparateThread = false;
private static final String COMPILE_ONLY_FLAG = "-Xcomp";

public GraalOSRLockTest() {
@BeforeClass
public static void checkVMArguments() {
try {
Class.forName("java.lang.management.ManagementFactory");
} catch (ClassNotFoundException ex) {
Assume.assumeNoException("cannot check for monitors without java.management JDK9 module", ex);
}
}

@BeforeClass
public static void checkVMArguments() {
/*
* Note: The -Xcomp execution mode of the VM will stop most of the OSR test cases from
* working as every method is compiled at level3 (followed by level4 on the second
Expand Down

0 comments on commit 8b83703

Please sign in to comment.