public class RunAftersWithOutputData
extends org.junit.runners.model.Statement
RunAfters method to write the test data to the file at the end of executing all the test
methods in the test cases.
This class also encapsulates the logic of running the reports after the test execution.
The reports are run asynchronously so that the Test cases do not get halted for the expensive run of the reports.| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG
An instance of logger associated with the test framework.
|
| Constructor and Description |
|---|
RunAftersWithOutputData(org.junit.runners.model.Statement next,
List<org.junit.runners.model.FrameworkMethod> afters,
Object target,
List<TestInfo> testInfoList,
Map<String,List<Map<String,Object>>> writableData,
ReportDataContainer testReportContainer)
Construct a new RunAftersWithOutputData
|
protected static final org.slf4j.Logger LOG
public RunAftersWithOutputData(org.junit.runners.model.Statement next,
List<org.junit.runners.model.FrameworkMethod> afters,
Object target,
List<TestInfo> testInfoList,
Map<String,List<Map<String,Object>>> writableData,
ReportDataContainer testReportContainer)
next - the instance of Statement objectafters - the list of FrameworkMethod that needs to be run after all the methods in the test class
have been executed.target - the target instance of the class. In this case it will always be null since methods with
AfterClass are always declared as static.testInfoList - the list of TestInfo containing information required to write data back to the file.writableData - the writable data that needs to be written to the file.testReportContainer - a container class representing everything required to generate reportspublic void evaluate()
throws Throwable
evaluate in class org.junit.runners.model.StatementThrowableRunAfters#evaluate()}Copyright © 2014. All rights reserved.