public class NonConcurrentRunListener extends JUnit4RunListener implements ConsoleOutputReceiver
Modifier and Type | Field and Description |
---|---|
private org.junit.runner.Description |
currentTestSetDescription |
private org.junit.runner.Description |
lastFinishedDescription |
reporter
Constructor and Description |
---|
NonConcurrentRunListener(RunListener reporter) |
Modifier and Type | Method and Description |
---|---|
protected SimpleReportEntry |
createReportEntry(org.junit.runner.Description description) |
private TestSetReportEntry |
createReportEntryForTestSet(org.junit.runner.Description description,
java.util.Map<java.lang.String,java.lang.String> systemProps) |
private TestSetReportEntry |
createTestSetReportEntryFinished(org.junit.runner.Description description) |
private TestSetReportEntry |
createTestSetReportEntryStarted(org.junit.runner.Description description) |
private boolean |
describesNewTestSet(org.junit.runner.Description description) |
protected java.lang.String |
extractDescriptionClassName(org.junit.runner.Description description) |
protected java.lang.String |
extractDescriptionMethodName(org.junit.runner.Description description) |
private void |
finishLastTestSetIfNecessary(org.junit.runner.Description description) |
void |
testAssumptionFailure(org.junit.runner.notification.Failure failure) |
void |
testFailure(org.junit.runner.notification.Failure failure)
Called when a specific test has failed.
|
void |
testFinished(org.junit.runner.Description description)
Called after a specific test has finished.
|
void |
testIgnored(org.junit.runner.Description description)
Called when a specific test has been skipped (for whatever reason).
|
void |
testRunFinished(org.junit.runner.Result result) |
void |
testRunStarted(org.junit.runner.Description description) |
void |
testStarted(org.junit.runner.Description description)
Called when a specific test has started.
|
void |
writeTestOutput(byte[] buf,
int off,
int len,
boolean stdout)
Forwards process output from the running test-case into the reporting system
|
createStackTraceWriter, rethrowAnyTestMechanismFailures, testExecutionSkippedByUser
private org.junit.runner.Description currentTestSetDescription
private org.junit.runner.Description lastFinishedDescription
public NonConcurrentRunListener(RunListener reporter) throws TestSetFailedException
TestSetFailedException
public void writeTestOutput(byte[] buf, int off, int len, boolean stdout)
ConsoleOutputReceiver
writeTestOutput
in interface ConsoleOutputReceiver
buf
- the buffer to writeoff
- offsetlen
- lenstdout
- Indicates if this is stdoutprotected SimpleReportEntry createReportEntry(org.junit.runner.Description description)
createReportEntry
in class JUnit4RunListener
private TestSetReportEntry createReportEntryForTestSet(org.junit.runner.Description description, java.util.Map<java.lang.String,java.lang.String> systemProps)
private TestSetReportEntry createTestSetReportEntryStarted(org.junit.runner.Description description)
private TestSetReportEntry createTestSetReportEntryFinished(org.junit.runner.Description description)
protected java.lang.String extractDescriptionClassName(org.junit.runner.Description description)
extractDescriptionClassName
in class JUnit4RunListener
protected java.lang.String extractDescriptionMethodName(org.junit.runner.Description description)
extractDescriptionMethodName
in class JUnit4RunListener
public void testStarted(org.junit.runner.Description description) throws java.lang.Exception
JUnit4RunListener
testStarted
in class JUnit4RunListener
java.lang.Exception
RunListener.testStarted(org.junit.runner.Description)
private void finishLastTestSetIfNecessary(org.junit.runner.Description description)
private boolean describesNewTestSet(org.junit.runner.Description description)
public void testFinished(org.junit.runner.Description description) throws java.lang.Exception
JUnit4RunListener
testFinished
in class JUnit4RunListener
java.lang.Exception
RunListener.testFinished(org.junit.runner.Description)
public void testIgnored(org.junit.runner.Description description) throws java.lang.Exception
JUnit4RunListener
testIgnored
in class JUnit4RunListener
java.lang.Exception
RunListener.testIgnored(org.junit.runner.Description)
public void testFailure(org.junit.runner.notification.Failure failure) throws java.lang.Exception
JUnit4RunListener
testFailure
in class JUnit4RunListener
java.lang.Exception
RunListener.testFailure(org.junit.runner.notification.Failure)
public void testAssumptionFailure(org.junit.runner.notification.Failure failure)
testAssumptionFailure
in class JUnit4RunListener
public void testRunStarted(org.junit.runner.Description description) throws java.lang.Exception
testRunStarted
in class org.junit.runner.notification.RunListener
java.lang.Exception
public void testRunFinished(org.junit.runner.Result result) throws java.lang.Exception
testRunFinished
in class org.junit.runner.notification.RunListener
java.lang.Exception