Package brave.test.util
Class GarbageCollectors
java.lang.Object
brave.test.util.GarbageCollectors
public final class GarbageCollectors extends Object
Utilities for working with the garbage collector in tests.
-
Method Summary
Modifier and Type Method Description static void
blockOnGC()
Runs the garbage collector and waits until all of the providedWeakReference
are cleared, indicating the referenced objects have been collected.
-
Method Details
-
blockOnGC
public static void blockOnGC()Runs the garbage collector and waits until all of the providedWeakReference
are cleared, indicating the referenced objects have been collected.
-