com.consol.citrus.report
Class JUnitReporter

java.lang.Object
  extended by com.consol.citrus.report.JUnitReporter
All Implemented Interfaces:
TestListener, TestReporter, TestSuiteListener

public class JUnitReporter
extends Object
implements TestSuiteListener, TestListener, TestReporter

TestReporter implementation that generates the famous JUnit XML reports. JUnit can use these XML reports to generate HTML reports.

Author:
Christoph Deppisch

Constructor Summary
JUnitReporter()
           
 
Method Summary
 void clearTestResults()
          Dismiss previous test results for next test run.
 void generateTestResults()
          Test reporter generates a report for several test suite instances.
 void onFinish()
          Invoked on test suite finish.
 void onFinishFailure(Throwable cause)
          Invoked after failed test suite finish.
 void onFinishSuccess()
          Invoked after successful test suite finish.
 void onStart()
          Invoked on test suite start.
 void onStartFailure(Throwable cause)
          Invoked after failed test suite start.
 void onStartSuccess()
          Invoked after successful test suite start.
 void onTestFailure(TestCase test, Throwable cause)
          Invoked when test finished with failure
 void onTestFinish(TestCase test)
          Invoked when test gets finished
 void onTestSkipped(TestCase test)
          Invoked when test is skipped
 void onTestStart(TestCase test)
          Invoked when test gets started
 void onTestSuccess(TestCase test)
          Invoked when test finished with success
 void setOutputFile(org.springframework.core.io.Resource outputFile)
          Set the target output time.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JUnitReporter

public JUnitReporter()
Method Detail

clearTestResults

public void clearTestResults()
Description copied from interface: TestReporter
Dismiss previous test results for next test run.

Specified by:
clearTestResults in interface TestReporter
See Also:
TestReporter.clearTestResults()

generateTestResults

public void generateTestResults()
Description copied from interface: TestReporter
Test reporter generates a report for several test suite instances.

Specified by:
generateTestResults in interface TestReporter
See Also:
TestReporter.generateTestResults()

onTestFailure

public void onTestFailure(TestCase test,
                          Throwable cause)
Description copied from interface: TestListener
Invoked when test finished with failure

Specified by:
onTestFailure in interface TestListener
See Also:
TestListener.onTestFailure(com.consol.citrus.TestCase, java.lang.Throwable)

onTestFinish

public void onTestFinish(TestCase test)
Description copied from interface: TestListener
Invoked when test gets finished

Specified by:
onTestFinish in interface TestListener
See Also:
TestListener.onTestFinish(com.consol.citrus.TestCase)

onTestSkipped

public void onTestSkipped(TestCase test)
Description copied from interface: TestListener
Invoked when test is skipped

Specified by:
onTestSkipped in interface TestListener
See Also:
TestListener.onTestSkipped(com.consol.citrus.TestCase)

onTestStart

public void onTestStart(TestCase test)
Description copied from interface: TestListener
Invoked when test gets started

Specified by:
onTestStart in interface TestListener
See Also:
TestListener.onTestStart(com.consol.citrus.TestCase)

onTestSuccess

public void onTestSuccess(TestCase test)
Description copied from interface: TestListener
Invoked when test finished with success

Specified by:
onTestSuccess in interface TestListener
See Also:
TestListener.onTestSuccess(com.consol.citrus.TestCase)

onFinish

public void onFinish()
Description copied from interface: TestSuiteListener
Invoked on test suite finish.

Specified by:
onFinish in interface TestSuiteListener
See Also:
TestSuiteListener.onFinish()

onFinishFailure

public void onFinishFailure(Throwable cause)
Description copied from interface: TestSuiteListener
Invoked after failed test suite finish.

Specified by:
onFinishFailure in interface TestSuiteListener
See Also:
TestSuiteListener.onFinishFailure(java.lang.Throwable)

onFinishSuccess

public void onFinishSuccess()
Description copied from interface: TestSuiteListener
Invoked after successful test suite finish.

Specified by:
onFinishSuccess in interface TestSuiteListener
See Also:
TestSuiteListener.onFinishSuccess()

onStart

public void onStart()
Description copied from interface: TestSuiteListener
Invoked on test suite start.

Specified by:
onStart in interface TestSuiteListener
See Also:
TestSuiteListener.onStart()

onStartFailure

public void onStartFailure(Throwable cause)
Description copied from interface: TestSuiteListener
Invoked after failed test suite start.

Specified by:
onStartFailure in interface TestSuiteListener
See Also:
TestSuiteListener.onStartFailure(java.lang.Throwable)

onStartSuccess

public void onStartSuccess()
Description copied from interface: TestSuiteListener
Invoked after successful test suite start.

Specified by:
onStartSuccess in interface TestSuiteListener
See Also:
TestSuiteListener.onStartSuccess()

setOutputFile

public void setOutputFile(org.springframework.core.io.Resource outputFile)
Set the target output time.

Parameters:
outputFile - the outputFile to set


Copyright © 2008-2013 ConSol* Consulting&Solutions GmbH. All Rights Reserved.