public class JUnitClassloaderRunner
extends org.junit.runners.BlockJUnit4ClassRunner
| Modifier and Type | Class and Description |
|---|---|
private class |
JUnitClassloaderRunner.SeparateClassLoaderInvokeMethod |
| Modifier and Type | Field and Description |
|---|---|
private static int |
HALT_TIME_S
Number of seconds to halt to allow for heap dump aquirement, if that option is enabled
|
| Constructor and Description |
|---|
JUnitClassloaderRunner(java.lang.Class<?> klass) |
| Modifier and Type | Method and Description |
|---|---|
private <T> T[] |
appendArrays(T[] arr1,
T[] arr2)
Append two arrays
|
private void |
dumpHeap(java.lang.String testName)
Create heap dump in file with same name as the test
|
static void |
forceGc()
Make sure Garbage Collection has been run
|
static void |
forceGc(int n)
Make sure Garbage Collection has been run N no of times
|
private java.io.File |
getSurefireReportsDirectory()
Try to find "target/surefire-reports" directory, assuming this is a Maven build.
|
private static java.io.File |
getSurefireReportsDirectory(java.lang.Class<?> clazz)
Try to find "target/surefire-reports" directory, assuming this is a Maven build.
|
protected org.junit.runners.model.Statement |
methodInvoker(org.junit.runners.model.FrameworkMethod method,
java.lang.Object test) |
private static void |
waitForHeapDump() |
collectInitializationErrors, computeTestMethods, createTest, describeChild, getChildren, getTestRules, isIgnored, methodBlock, possiblyExpectingExceptions, rules, runChild, testName, validateConstructor, validateFields, validateInstanceMethods, validateNoNonStaticInnerClass, validateOnlyOneConstructor, validateTestMethods, validateZeroArgConstructor, withAfters, withBefores, withPotentialTimeoutprivate static final int HALT_TIME_S
public JUnitClassloaderRunner(java.lang.Class<?> klass)
throws org.junit.runners.model.InitializationError
org.junit.runners.model.InitializationErrorprotected org.junit.runners.model.Statement methodInvoker(org.junit.runners.model.FrameworkMethod method,
java.lang.Object test)
methodInvoker in class org.junit.runners.BlockJUnit4ClassRunnerpublic static void forceGc(int n)
public static void forceGc()
private static void waitForHeapDump()
throws java.lang.InterruptedException
java.lang.InterruptedExceptionprivate void dumpHeap(java.lang.String testName)
private java.io.File getSurefireReportsDirectory()
private static java.io.File getSurefireReportsDirectory(java.lang.Class<?> clazz)
private <T> T[] appendArrays(T[] arr1,
T[] arr2)