Package | Description |
---|---|
org.junit.experimental.theories | |
org.junit.internal.runners.statements | |
org.junit.rules | |
org.junit.runners |
Provides standard
Runner implementations. |
org.junit.runners.parameterized |
Modifier and Type | Class and Description |
---|---|
static class |
Theories.TheoryAnchor |
Modifier and Type | Method and Description |
---|---|
Statement |
Theories.methodBlock(FrameworkMethod method) |
Modifier and Type | Class and Description |
---|---|
class |
ExpectException |
class |
Fail |
class |
FailOnTimeout |
class |
InvokeMethod |
class |
RunAfters |
class |
RunBefores |
Modifier and Type | Method and Description |
---|---|
FailOnTimeout |
FailOnTimeout.Builder.build(Statement statement)
Builds a
FailOnTimeout instance using the values in this builder,
wrapping the given statement. |
Constructor and Description |
---|
ExpectException(Statement next,
Class<? extends Throwable> expected) |
FailOnTimeout(Statement statement,
long timeoutMillis)
Deprecated.
use
FailOnTimeout.builder() instead. |
RunAfters(Statement next,
List<FrameworkMethod> afters,
Object target) |
RunBefores(Statement next,
List<FrameworkMethod> befores,
Object target) |
Modifier and Type | Class and Description |
---|---|
class |
RunRules
Runs a collection of rules on a statement.
|
Modifier and Type | Method and Description |
---|---|
Statement |
TestWatcher.apply(Statement base,
Description description) |
Statement |
ExpectedException.apply(Statement base,
Description description) |
Statement |
DisableOnDebug.apply(Statement base,
Description description) |
Statement |
Timeout.apply(Statement base,
Description description) |
Statement |
Verifier.apply(Statement base,
Description description) |
Statement |
RuleChain.apply(Statement base,
Description description)
Modifies the method-running
Statement to implement this
test-running rule. |
Statement |
TestRule.apply(Statement base,
Description description)
Modifies the method-running
Statement to implement this
test-running rule. |
Statement |
Stopwatch.apply(Statement base,
Description description) |
Statement |
ExternalResource.apply(Statement base,
Description description) |
Statement |
MethodRule.apply(Statement base,
FrameworkMethod method,
Object target)
Modifies the method-running
Statement to implement an additional
test-running rule. |
Statement |
TestWatchman.apply(Statement base,
FrameworkMethod method,
Object target)
Deprecated.
|
protected Statement |
Timeout.createFailOnTimeoutStatement(Statement statement)
Creates a
Statement that will run the given
statement , and timeout the operation based
on the values configured in this rule. |
Modifier and Type | Method and Description |
---|---|
Statement |
TestWatcher.apply(Statement base,
Description description) |
Statement |
ExpectedException.apply(Statement base,
Description description) |
Statement |
DisableOnDebug.apply(Statement base,
Description description) |
Statement |
Timeout.apply(Statement base,
Description description) |
Statement |
Verifier.apply(Statement base,
Description description) |
Statement |
RuleChain.apply(Statement base,
Description description)
Modifies the method-running
Statement to implement this
test-running rule. |
Statement |
TestRule.apply(Statement base,
Description description)
Modifies the method-running
Statement to implement this
test-running rule. |
Statement |
Stopwatch.apply(Statement base,
Description description) |
Statement |
ExternalResource.apply(Statement base,
Description description) |
Statement |
MethodRule.apply(Statement base,
FrameworkMethod method,
Object target)
Modifies the method-running
Statement to implement an additional
test-running rule. |
Statement |
TestWatchman.apply(Statement base,
FrameworkMethod method,
Object target)
Deprecated.
|
protected Statement |
Timeout.createFailOnTimeoutStatement(Statement statement)
Creates a
Statement that will run the given
statement , and timeout the operation based
on the values configured in this rule. |
Constructor and Description |
---|
RunRules(Statement base,
Iterable<TestRule> rules,
Description description) |
Modifier and Type | Method and Description |
---|---|
protected Statement |
ParentRunner.childrenInvoker(RunNotifier notifier)
Returns a
Statement : Call ParentRunner.runChild(Object, RunNotifier)
on each object returned by ParentRunner.getChildren() (subject to any imposed
filter and sort) |
protected Statement |
ParentRunner.classBlock(RunNotifier notifier)
Constructs a
Statement to run all of the tests in the test class. |
protected Statement |
BlockJUnit4ClassRunner.methodBlock(FrameworkMethod method)
Returns a Statement that, when executed, either returns normally if
method passes, or throws an exception if method fails. |
protected Statement |
BlockJUnit4ClassRunner.methodInvoker(FrameworkMethod method,
Object test)
|
protected Statement |
BlockJUnit4ClassRunner.possiblyExpectingExceptions(FrameworkMethod method,
Object test,
Statement next)
Returns a
Statement : if method 's @Test annotation
has the expecting attribute, return normally only if next
throws an exception of the correct type, and throw an exception
otherwise. |
protected Statement |
ParentRunner.withAfterClasses(Statement statement)
Returns a
Statement : run all non-overridden @AfterClass methods on this class
and superclasses before executing statement ; all AfterClass methods are
always executed: exceptions thrown by previous steps are combined, if
necessary, with exceptions from AfterClass methods into a
MultipleFailureException . |
protected Statement |
BlockJUnit4ClassRunner.withAfters(FrameworkMethod method,
Object target,
Statement statement)
Returns a
Statement : run all non-overridden @After
methods on this class and superclasses before running next ; all
After methods are always executed: exceptions thrown by previous steps
are combined, if necessary, with exceptions from After methods into a
MultipleFailureException . |
protected Statement |
ParentRunner.withBeforeClasses(Statement statement)
Returns a
Statement : run all non-overridden @BeforeClass methods on this class
and superclasses before executing statement ; if any throws an
Exception, stop execution and pass the exception on. |
protected Statement |
BlockJUnit4ClassRunner.withBefores(FrameworkMethod method,
Object target,
Statement statement)
Returns a
Statement : run all non-overridden @Before
methods on this class and superclasses before running next ; if
any throws an Exception, stop execution and pass the exception on. |
protected Statement |
BlockJUnit4ClassRunner.withPotentialTimeout(FrameworkMethod method,
Object test,
Statement next)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
protected Statement |
BlockJUnit4ClassRunner.possiblyExpectingExceptions(FrameworkMethod method,
Object test,
Statement next)
Returns a
Statement : if method 's @Test annotation
has the expecting attribute, return normally only if next
throws an exception of the correct type, and throw an exception
otherwise. |
protected void |
ParentRunner.runLeaf(Statement statement,
Description description,
RunNotifier notifier)
Runs a
Statement that represents a leaf (aka atomic) test. |
protected Statement |
ParentRunner.withAfterClasses(Statement statement)
Returns a
Statement : run all non-overridden @AfterClass methods on this class
and superclasses before executing statement ; all AfterClass methods are
always executed: exceptions thrown by previous steps are combined, if
necessary, with exceptions from AfterClass methods into a
MultipleFailureException . |
protected Statement |
BlockJUnit4ClassRunner.withAfters(FrameworkMethod method,
Object target,
Statement statement)
Returns a
Statement : run all non-overridden @After
methods on this class and superclasses before running next ; all
After methods are always executed: exceptions thrown by previous steps
are combined, if necessary, with exceptions from After methods into a
MultipleFailureException . |
protected Statement |
ParentRunner.withBeforeClasses(Statement statement)
Returns a
Statement : run all non-overridden @BeforeClass methods on this class
and superclasses before executing statement ; if any throws an
Exception, stop execution and pass the exception on. |
protected Statement |
BlockJUnit4ClassRunner.withBefores(FrameworkMethod method,
Object target,
Statement statement)
Returns a
Statement : run all non-overridden @Before
methods on this class and superclasses before running next ; if
any throws an Exception, stop execution and pass the exception on. |
protected Statement |
BlockJUnit4ClassRunner.withPotentialTimeout(FrameworkMethod method,
Object test,
Statement next)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
protected Statement |
BlockJUnit4ClassRunnerWithParameters.classBlock(RunNotifier notifier) |
Copyright © 2002–2021 JUnit. All rights reserved.