summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/163-app-image-methods/src/Main.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/163-app-image-methods/src/Main.java b/test/163-app-image-methods/src/Main.java
index a995bb8412..c513470b7b 100644
--- a/test/163-app-image-methods/src/Main.java
+++ b/test/163-app-image-methods/src/Main.java
@@ -22,6 +22,9 @@ public class Main {
// Allocate memory for the "AAA.Derived" class name before eating memory.
String aaaDerivedName = "AAA.Derived";
System.out.println("Eating all memory.");
+ // Resolve VMClassLoader before eating all the memory since we can not fail
+ // initializtaion of boot classpath classes.
+ Class.forName("java.lang.VMClassLoader");
Object memory = eatAllMemory();
// This test assumes that Derived is not yet resolved. In some configurations