UnitTest++ Post-Processor
The UnitTest++ post-processor can be used to process XML reports in the format produced by the XmltestReporter class in UnitTest++
, adding the test results to the build result.
Attibutes
| Attribute |
Description |
Required? |
Default |
| fail-on-failure |
If true, the build will be failed if any test failures are detected by this processor. |
No |
true |
| name |
The name of the post-processor. |
Yes |
|
| suite |
If a suite is specified, all tests found by this processor will be added to that suite. |
No |
|
Child Elements
None.
Examples
Create and apply a UnitTest++ post-processor to a captured test report:
<unittestpp.pp name="unittestpp"/>
<recipe name="default">
<command name="build">
<make targets="test"/>
<artifact name="unittest++ xml report" file="build/reports/UnitTestPP.xml" fail-if-not-present="false">
<process processor="${unittestpp}"/>
</artifact>
</command>
</recipe>
Capture a directory of reports and process them all:
<unittestpp.pp name="unittestpp"/>
<recipe name="default">
<command name="build">
<make targets="test"/>
<dir-artifact name="test reports" base="${base.dir}/reports" fail-if-not-present="false">
<include pattern="**/*.xml"/>
<process processor="${unittestpp}"/>
</dir-artifact>
</command>
</recipe>