org.junit.runner.notification
Class RunNotifier
java.lang.Object
org.junit.runner.notification.RunNotifier
public class RunNotifier
extends java.lang.Object
addFirstListener
public void addFirstListener(RunListener listener)
Internal use only. The Result's listener must be first.
addListener
public void addListener(RunListener listener)
Internal use only
fireTestFailure
public void fireTestFailure(Failure failure)
Invoke to tell listeners that an atomic test failed.
failure
- the description of the test that failed and the exception thrown
fireTestFinished
public void fireTestFinished(Description description)
description
- the description of the test that finished
fireTestIgnored
public void fireTestIgnored(Description description)
Invoke to tell listeners that an atomic test was ignored.
description
- the description of the ignored test
fireTestRunFinished
public void fireTestRunFinished(Result result)
Do not invoke.
fireTestRunStarted
public void fireTestRunStarted(Description description)
Do not invoke.
fireTestStarted
public void fireTestStarted(Description description)
throws StoppedByUserException
Invoke to tell listeners that an atomic test is about to start.
description
- the description of the atomic test (generally a class and method name)
pleaseStop
public void pleaseStop()
Ask that the tests run stop before starting the next test. Phrased politely because
the test currently running will not be interrupted. It seems a little odd to put this
functionality here, but the RunNotifier
is the only object guaranteed
to be shared amongst the many runners involved.
removeListener
public void removeListener(RunListener listener)
Internal use only
testAborted
public void testAborted(Description description,
Throwable cause)