Skip to content

Commit a6564d4

Browse files
committedAug 2, 2022
8291650: Add delay to ClassUnloadEventTest before exiting to give time for JVM to send all events before VMDeath
Reviewed-by: sspitsyn, amenkov
1 parent af76c0c commit a6564d4

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed
 

‎test/jdk/com/sun/jdi/ClassUnloadEventTest.java

+7
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,13 @@ private static void runDebuggee() {
102102
loader = null;
103103
// Trigger class unloading
104104
ClassUnloadCommon.triggerUnloading();
105+
106+
// Short delay to make sure all ClassUnloadEvents have been sent
107+
// before VMDeathEvent is genareated.
108+
try {
109+
Thread.sleep(5000);
110+
} catch (InterruptedException e) {
111+
}
105112
}
106113

107114
private static void runDebugger() throws Exception {

0 commit comments

Comments
 (0)
Please sign in to comment.