It's all about the answers!

Ask a question

Can RTC ANT task junitLogPublisher display skipped tests


Sue Bayliss (61) | asked Mar 29 '17, 7:06 a.m.

Does the junitLogPublisher ANT task support the skipped junit XML attribute? And is it possible for the number of skipped tests to be reported on RTC build output Overview tab Tests summary counts and displayed with a different icon/status on the Tests tab?

I am using RTC ANT task junitLogPublisher to display the results of our JUnit tests in the RTC build output,, where filepath is set to the XML format results file output from the ANT 1.9.4 junit task. Some of our tests are intentionally skipped (using org.junit.Assume.assumeTrue(false);). So the junit XML results file contains:

<testsuite errors="0" failures="0" hostname="myhost" name="mytestSuite" skipped="1" tests="9" time="61.078" timestamp="2017-03-29T10:10:14">
and
<testcase classname="myTestClass" name="myTestName" time="0.019">
    <skipped message="failed assumption: 2017-03-29-10:10:57:314 got: &lt;false&gt;, expected: is &lt;true&gt;" />
</testcase>
At runtime the following error is reported:
[junitLogPublisher] Non-fatal errors occurred while publishing "myTestSuite.xml":
[junitLogPublisher]     Found unexpected element "skipped" inside element "testcase".
The build result Overview tab reports "Tests: 9 tests, 0 failures, 0 errors" (but no info about the skipped test) and the Tests tab reports the skipped tests as a pass.

Using RTC build engine product.release.label=4.0.6
Thanks

Be the first one to answer this question!


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.