org.apache.maven.surefire.report
Interface Reporter

All Known Implementing Classes:
AbstractConsoleReporter, AbstractFileReporter, AbstractReporter, AbstractTextReporter, BriefConsoleReporter, BriefFileReporter, ConsoleReporter, DetailedConsoleReporter, FileReporter, ForkingConsoleReporter, MulticastingReporter, TestSetRunListener, XMLReporter

public interface Reporter

Persists reports somewhere

An instance of a reporter is not guaranteed to be thread-safe and concurrent test frameworks must request an instance of a reporter per-thread from the ReporterFactory.


Method Summary
 void reset()
          Restores the instance of the reporter, making the instance re-usable for a subsequent run in the same thread.
 void testError(ReportEntry report)
          Event fired when a test ended with an error (non anticipated problem)
 void testError(ReportEntry report, String stdOut, String stdErr)
          Event fired when a test ended with an error (non anticipated problem)
 void testFailed(ReportEntry report)
          Event fired when a test ended with a failure (anticipated problem)
 void testFailed(ReportEntry report, String stdOut, String stdErr)
          Event fired when a test ended with a failure (anticipated problem)
 void testSetCompleted(ReportEntry report)
          Indicates end of a given test-set
 void testSetStarting(ReportEntry report)
          Indicates the start of a given test-set
 void testSkipped(ReportEntry report)
           
 void testStarting(ReportEntry report)
          Event fired when a test is about to start
 void testSucceeded(ReportEntry report)
          Event fired when a test ended successfully
 void writeDetailMessage(String message)
          Writes a detailed message that will not necessarily be displayed in all channels.
 void writeFooter(String footer)
           
 void writeMessage(String message)
          Writes a message that will be displayed in all free-text format reporters.
 

Method Detail

testSetStarting

void testSetStarting(ReportEntry report)
                     throws ReporterException
Indicates the start of a given test-set

Parameters:
report - the report entry describing the testset
Throws:
ReporterException - When reporting fails

testSetCompleted

void testSetCompleted(ReportEntry report)
                      throws ReporterException
Indicates end of a given test-set

Parameters:
report - the report entry describing the testset
Throws:
ReporterException - When reporting fails

testStarting

void testStarting(ReportEntry report)
Event fired when a test is about to start

Parameters:
report - The report entry to log for

testSucceeded

void testSucceeded(ReportEntry report)
Event fired when a test ended successfully

Parameters:
report - The report entry to log for

testError

void testError(ReportEntry report)
Event fired when a test ended with an error (non anticipated problem)

Parameters:
report - The report entry to log for

testFailed

void testFailed(ReportEntry report)
Event fired when a test ended with a failure (anticipated problem)

Parameters:
report - The report entry to log for

testSkipped

void testSkipped(ReportEntry report)

testError

void testError(ReportEntry report,
               String stdOut,
               String stdErr)
Event fired when a test ended with an error (non anticipated problem)

Parameters:
report - The report entry to log for
stdOut - standard output from the test case
stdErr - error output from the test case

testFailed

void testFailed(ReportEntry report,
                String stdOut,
                String stdErr)
Event fired when a test ended with a failure (anticipated problem)

Parameters:
report - The report entry to log for
stdOut - standard output from the test case
stdErr - error output from the test case

writeMessage

void writeMessage(String message)
Writes a message that will be displayed in all free-text format reporters. These messages will be output regardless, as opposed to #writeDetailMessage, which is controlled by reportFormat.

Parameters:
message - The message to write.

writeDetailMessage

void writeDetailMessage(String message)
Writes a detailed message that will not necessarily be displayed in all channels. This is controlled by reportFormat attribute on the plugin.

Parameters:
message - The message to write

reset

void reset()
Restores the instance of the reporter, making the instance re-usable for a subsequent run in the same thread.


writeFooter

void writeFooter(String footer)


Copyright © 2004-2011 The Apache Software Foundation. All Rights Reserved.