Package org.jgroups.util
Class JUnitXMLReporter
java.lang.Object
org.testng.TestListenerAdapter
org.jgroups.util.JUnitXMLReporter
- All Implemented Interfaces:
org.testng.IInvokedMethodListener,org.testng.internal.IConfigurationListener,org.testng.internal.IResultListener,org.testng.ITestListener,org.testng.ITestNGListener
public class JUnitXMLReporter
extends org.testng.TestListenerAdapter
implements org.testng.IInvokedMethodListener
Listener generating XML output suitable to be processed by JUnitReport.
Copied from TestNG (www.testng.org) and modified
- Author:
- Bela Ban
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidafterInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult tr) Invoked after any method (configuration or test) is invokedvoidbeforeInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult tr) Invoked before any method (configuration or test) is invokedprotected voidgenerateReport(Class<?> clazz, List<org.testng.ITestResult> results) generate the XML report given what we know from all the test resultsvoidonFinish(org.testng.ITestContext context) Invoked after all the tests have run and all their Configuration methods have been called.voidonStart(org.testng.ITestContext context) Invoked after the test class is instantiated and before any configuration method is called.voidonTestFailedButWithinSuccessPercentage(org.testng.ITestResult tr) voidonTestFailure(org.testng.ITestResult tr) Invoked each time a test fails.voidonTestSkipped(org.testng.ITestResult tr) Invoked each time a test is skipped.voidonTestStart(org.testng.ITestResult result) voidonTestSuccess(org.testng.ITestResult tr) Invoked each time a test succeedsMethods inherited from class org.testng.TestListenerAdapter
getAllTestMethods, getConfigurationFailures, getConfigurationSkips, getFailedButWithinSuccessPercentageTests, getFailedTests, getPassedTests, getSkippedTests, getTestContexts, onConfigurationFailure, onConfigurationSkip, onConfigurationSuccess, setAllTestMethods, setFailedButWithinSuccessPercentageTests, setFailedTests, setPassedTests, setSkippedTests
-
Field Details
-
local
-
-
Constructor Details
-
JUnitXMLReporter
public JUnitXMLReporter()
-
-
Method Details
-
beforeInvocation
public void beforeInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult tr) Invoked before any method (configuration or test) is invoked- Specified by:
beforeInvocationin interfaceorg.testng.IInvokedMethodListener
-
afterInvocation
public void afterInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult tr) Invoked after any method (configuration or test) is invoked- Specified by:
afterInvocationin interfaceorg.testng.IInvokedMethodListener
-
onTestStart
public void onTestStart(org.testng.ITestResult result) - Specified by:
onTestStartin interfaceorg.testng.ITestListener- Overrides:
onTestStartin classorg.testng.TestListenerAdapter
-
onTestSuccess
public void onTestSuccess(org.testng.ITestResult tr) Invoked each time a test succeeds- Specified by:
onTestSuccessin interfaceorg.testng.ITestListener- Overrides:
onTestSuccessin classorg.testng.TestListenerAdapter
-
onTestFailedButWithinSuccessPercentage
public void onTestFailedButWithinSuccessPercentage(org.testng.ITestResult tr) - Specified by:
onTestFailedButWithinSuccessPercentagein interfaceorg.testng.ITestListener- Overrides:
onTestFailedButWithinSuccessPercentagein classorg.testng.TestListenerAdapter
-
onTestFailure
public void onTestFailure(org.testng.ITestResult tr) Invoked each time a test fails.- Specified by:
onTestFailurein interfaceorg.testng.ITestListener- Overrides:
onTestFailurein classorg.testng.TestListenerAdapter
-
onTestSkipped
public void onTestSkipped(org.testng.ITestResult tr) Invoked each time a test is skipped.- Specified by:
onTestSkippedin interfaceorg.testng.ITestListener- Overrides:
onTestSkippedin classorg.testng.TestListenerAdapter
-
onStart
public void onStart(org.testng.ITestContext context) Invoked after the test class is instantiated and before any configuration method is called.- Specified by:
onStartin interfaceorg.testng.ITestListener- Overrides:
onStartin classorg.testng.TestListenerAdapter
-
onFinish
public void onFinish(org.testng.ITestContext context) Invoked after all the tests have run and all their Configuration methods have been called.- Specified by:
onFinishin interfaceorg.testng.ITestListener- Overrides:
onFinishin classorg.testng.TestListenerAdapter
-
generateReport
protected void generateReport(Class<?> clazz, List<org.testng.ITestResult> results) throws IOException generate the XML report given what we know from all the test results- Throws:
IOException
-