public interface Reporter
Modifier and Type | Method and Description |
---|---|
default void |
blockHookFail(Hook hook,
java.util.List<TestBlock> parents,
java.lang.Throwable cause)
Called when a before or after hook failed due to it throwing an exception.
|
default void |
blockHookPass(Hook hook,
java.util.List<TestBlock> parents)
Called after a before or after hook has successfully executed without throwing an exception.
|
default void |
blockHookStart(Hook hook,
java.util.List<TestBlock> parents)
Called before a before or after hook is run.
|
default void |
end()
Called after all tests have been run.
|
default void |
hookFail(Hook hook,
java.util.List<TestBlock> parents,
java.lang.Throwable cause)
Deprecated.
|
default void |
start(TestBlock rootBlock)
Called before any tests are run.
|
default void |
testBlockEnd(TestBlock testBlock,
java.util.List<TestBlock> parents)
Called after all tests in a test block have completed.
|
default void |
testBlockStart(TestBlock testBlock,
java.util.List<TestBlock> parents)
Called before any tests are run in a test block.
|
default void |
testEnd(Test test,
java.util.List<TestBlock> parents)
Called after a test is run.
|
default void |
testFail(Test test,
java.util.List<TestBlock> parents,
java.lang.Throwable cause)
Called after a test has failed due to it throwing an exception.
|
default void |
testHookFail(Hook hook,
java.util.List<TestBlock> hookParents,
Test test,
java.util.List<TestBlock> testParents,
java.lang.Throwable cause)
Called when a beforeEach or afterEach hook failed due to it throwing an exception.
|
default void |
testHookPass(Hook hook,
java.util.List<TestBlock> hookParents,
Test test,
java.util.List<TestBlock> testParents)
Called after a beforeEach or afterEach hook has successfully executed without throwing an exception.
|
default void |
testHookStart(Hook hook,
java.util.List<TestBlock> hookParents,
Test test,
java.util.List<TestBlock> testParents)
Called before a beforeEach or afterEach hook is run.
|
default void |
testPass(Test test,
java.util.List<TestBlock> parents)
Called after a test has successfully executed without throwing an exception.
|
default void |
testPending(Test test,
java.util.List<TestBlock> parents)
Called when a test cannot be run as it has not yet been implemented.
|
default void |
testSkip(Test test,
java.util.List<TestBlock> parents)
Called when a test has been skipped.
|
default void |
testStart(Test test,
java.util.List<TestBlock> parents)
Called before a test is run.
|
default void start(TestBlock rootBlock)
rootBlock
- The root test block containing all the tests that will be run.default void end()
default void testBlockStart(TestBlock testBlock, java.util.List<TestBlock> parents)
testBlock
- The test block.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.default void testBlockEnd(TestBlock testBlock, java.util.List<TestBlock> parents)
testBlock
- The test block.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.default void testHookStart(Hook hook, java.util.List<TestBlock> hookParents, Test test, java.util.List<TestBlock> testParents)
hook
- The hook that threw an exception.hookParents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.test
- The test that was associated with the beforeEach/afterEach.testParents
- The parent test blocks of the test, starting with the root block and ending with the immediate
parent.default void blockHookStart(Hook hook, java.util.List<TestBlock> parents)
hook
- The hook that threw an exception.parents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.default void testHookPass(Hook hook, java.util.List<TestBlock> hookParents, Test test, java.util.List<TestBlock> testParents)
hook
- The hook that threw an exception.hookParents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.test
- The test that was associated with the beforeEach/afterEach.testParents
- The parent test blocks of the test, starting with the root block and ending with the immediate
parent.default void blockHookPass(Hook hook, java.util.List<TestBlock> parents)
hook
- The hook that threw an exception.parents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.default void testHookFail(Hook hook, java.util.List<TestBlock> hookParents, Test test, java.util.List<TestBlock> testParents, java.lang.Throwable cause)
hook
- The hook that threw an exception.hookParents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.test
- The test that was associated with the beforeEach/afterEach.testParents
- The parent test blocks of the test, starting with the root block and ending with the immediate
parent.cause
- The throwable that the hook threw.default void blockHookFail(Hook hook, java.util.List<TestBlock> parents, java.lang.Throwable cause)
hook
- The hook that threw an exception.parents
- The parent test blocks of the hook, starting with the root block and ending with the immediate
parent.cause
- The throwable that the hook threw.@Deprecated default void hookFail(Hook hook, java.util.List<TestBlock> parents, java.lang.Throwable cause)
testHookFail(Hook, List, Test, List, Throwable)
and
blockHookFail(Hook, List, Throwable)
instead.hook
- The hook that threw an exception.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.cause
- The throwable that the hook threw.default void testStart(Test test, java.util.List<TestBlock> parents)
test
- The test that is being run.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.default void testEnd(Test test, java.util.List<TestBlock> parents)
test
- The test that has been run.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.default void testPass(Test test, java.util.List<TestBlock> parents)
test
- The test that passed.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.default void testFail(Test test, java.util.List<TestBlock> parents, java.lang.Throwable cause)
test
- The test that failed.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.cause
- The assertion error that the test threw.default void testPending(Test test, java.util.List<TestBlock> parents)
test
- The pending test.parents
- The ancestor test blocks, starting with the root block and ending with the immediate parent.