org.apache.tools.ant.taskdefs.optional.junit

Class SummaryJUnitResultFormatter

Implemented Interfaces:
JUnitResultFormatter, TestListener

public class SummaryJUnitResultFormatter
extends java.lang.Object
implements JUnitResultFormatter

Prints short summary output of the test to Ant's logging system.

Constructor Summary

SummaryJUnitResultFormatter()
Empty

Method Summary

void
addError(Test test, Throwable t)
Empty
void
addFailure(Test test, AssertionFailedError t)
Interface TestListener for JUnit > 3.4.
void
addFailure(Test test, Throwable t)
Empty
void
endTest(Test test)
Empty
void
endTestSuite(JUnitTest suite)
The whole testsuite ended.
void
setOutput(OutputStream out)
Sets the stream the formatter is supposed to write its results to.
void
setSystemError(String err)
This is what the test has written to System.err
void
setSystemOutput(String out)
This is what the test has written to System.out
void
setWithOutAndErr(boolean value)
Should the output to System.out and System.err be written to the summary.
void
startTest(Test t)
Empty
void
startTestSuite(JUnitTest suite)
Empty

Constructor Details

SummaryJUnitResultFormatter

public SummaryJUnitResultFormatter()
Empty

Method Details

addError

public void addError(Test test,
                     Throwable t)
Empty


addFailure

public void addFailure(Test test,
                       AssertionFailedError t)
Interface TestListener for JUnit > 3.4.

A Test failed.


addFailure

public void addFailure(Test test,
                       Throwable t)
Empty


endTest

public void endTest(Test test)
Empty


endTestSuite

public void endTestSuite(JUnitTest suite)
            throws BuildException
The whole testsuite ended.
Specified by:
endTestSuite in interface JUnitResultFormatter


setOutput

public void setOutput(OutputStream out)
Sets the stream the formatter is supposed to write its results to.
Specified by:
setOutput in interface JUnitResultFormatter


setSystemError

public void setSystemError(String err)
This is what the test has written to System.err
Specified by:
setSystemError in interface JUnitResultFormatter


setSystemOutput

public void setSystemOutput(String out)
This is what the test has written to System.out
Specified by:
setSystemOutput in interface JUnitResultFormatter


setWithOutAndErr

public void setWithOutAndErr(boolean value)
Should the output to System.out and System.err be written to the summary.


startTest

public void startTest(Test t)
Empty


startTestSuite

public void startTestSuite(JUnitTest suite)
Empty
Specified by:
startTestSuite in interface JUnitResultFormatter


Copyright B) 2000-2005 Apache Software Foundation. All Rights Reserved.