Package step.reporting
Class JUnit4ReportWriter
java.lang.Object
step.reporting.JUnit4ReportWriter
- All Implemented Interfaces:
ReportWriter
A
ReportWriter
that generates JUnit 4 XML reports based on the JUnit schema https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
formatTime
(long duration) protected void
writeErrorOrFailure
(BufferedWriter writer, ReportNode node, AtomicBoolean errorWritten) void
writeReport
(ReportTreeAccessor reportTreeAccessor, String executionId, File outputFile) Writes the report of the provided execution
-
Constructor Details
-
JUnit4ReportWriter
public JUnit4ReportWriter()
-
-
Method Details
-
writeReport
public void writeReport(ReportTreeAccessor reportTreeAccessor, String executionId, File outputFile) throws IOException Description copied from interface:ReportWriter
Writes the report of the provided execution- Specified by:
writeReport
in interfaceReportWriter
- Parameters:
reportTreeAccessor
- theReportTreeAccessor
to be used to access the report node treeexecutionId
- the ID of the execution to be reportedoutputFile
- the output file the report has to be written to- Throws:
IOException
- if an error occurs while writing the report
-
writeErrorOrFailure
protected void writeErrorOrFailure(BufferedWriter writer, ReportNode node, AtomicBoolean errorWritten) throws IOException - Throws:
IOException
-
formatTime
-