public class ThreadDump extends Object
Modifier and Type | Field and Description |
---|---|
static String |
IGNORE_THREAD_IF_IN_NAME |
Constructor and Description |
---|
ThreadDump() |
Modifier and Type | Method and Description |
---|---|
static void |
add(Thread t,
StackTrace stackTrace) |
void |
assertNoNewThreads()
Waits for all new threads to finish execution, up for 50ms.
|
void |
assertNoNewThreads(int delay,
TimeUnit delayUnit)
Waits for all new threads to finish execution, up for the specified amount of time ± 50ms.
|
static StackTrace |
createdHereFor(Thread thread) |
void |
ignore(String threadName) |
public static final String IGNORE_THREAD_IF_IN_NAME
public static void add(Thread t, StackTrace stackTrace)
public void ignore(String threadName)
public void assertNoNewThreads()
Then, prints 3 warnings after 0ms, 200ms and 650ms. Then, throws an exception after 800ms.
public static StackTrace createdHereFor(Thread thread)
public void assertNoNewThreads(int delay, @NotNull TimeUnit delayUnit)
Then, prints 3 warnings after 0ms, 200ms and 650ms. Then, throws an exception after 800ms.
Copyright © 2020. All rights reserved.