public class TestReporting extends Object
Constructor and Description |
---|
TestReporting() |
Modifier and Type | Method and Description |
---|---|
void |
finishedTestCase(String testName,
boolean passed)
Invoked when a unit test has completed
|
void |
finishedTestCase(UnitTest test,
boolean passed)
Deprecated.
this method is no longer invoked by the testing framework; please use
finishedTestCase(String, boolean) |
static TestReporting |
getInstance()
Gets the test reporting instance
|
void |
logException(Throwable err)
Indicates an error from the current test case
|
void |
logMessage(String message)
Indicates a message from the current test case
|
static void |
setInstance(TestReporting i)
Sets the test reporting instance to a subclass of this class.
|
void |
startingTestCase(String testName)
Invoked when a unit test is started
|
void |
startingTestCase(UnitTest test)
Deprecated.
this method is no longer invoked by the testing framework; please use
startingTestCase(String) |
void |
testExecutionFinished()
Deprecated.
this method is no longer invoked by the testing framework; please use
testExecutionFinished(String) |
void |
testExecutionFinished(String testSuiteName)
Callback to indicate the test execution has finished allowing
for a report to be generated if appropriate
|
void |
writeReport(OutputStream os)
Deprecated.
this method is no longer invoked by the testing framework; please use
writeReport(String, OutputStream) |
void |
writeReport(String testSuiteName,
OutputStream os)
Writes a test report to the given stream
|
public static TestReporting getInstance()
public static void setInstance(TestReporting i)
i
- the new instancepublic void startingTestCase(String testName)
public void startingTestCase(UnitTest test)
startingTestCase(String)
public void logMessage(String message)
message
- the messagepublic void logException(Throwable err)
err
- the error messagepublic void finishedTestCase(String testName, boolean passed)
testName
- the name of the test casepassed
- true if the test passed and false otherwisepublic void finishedTestCase(UnitTest test, boolean passed)
finishedTestCase(String, boolean)
public void writeReport(String testSuiteName, OutputStream os) throws IOException
testSuiteName
- the name of the test suiteos
- the destination streamIOException
public void writeReport(OutputStream os) throws IOException
writeReport(String, OutputStream)
IOException
public void testExecutionFinished(String testSuiteName)
public void testExecutionFinished()
testExecutionFinished(String)