Issue Type: Bug Bug
Affects Versions: current
Assignee: Gregory Boissinot
Attachments: TEST-MyTest.xml
Components: xunit
Created: 13/Jun/13 7:23 PM
Description:

Running a simple Gradle configuration, the xUnit plugin cannot validate JUnit output files because the <properties> element is empty. There does not appear to be a canonical schema for JUnit XML output, but informal sources (eg, http://windyroad.com.au/2011/02/07/apache-ant-junit-xml-schema/) allow 0..n <property> tags inside of a <properties> tag.

Jenkins gives the following output:

Jun 12, 2013 7:00:13 PM com.thalesgroup.hudson.plugins.xunit.service.XUnitService errorSystemLogger
SEVERE: [xUnit] - The result file 'C:\Programs\jenkins\jobs\Midas Testing\workspace\ssi\build\test-results\TEST-com.stottlerhenke.ssi.report.io.TestReportConfig.xml' for the metric 'JUnit' is not valid. The result file has been skipped.

Jun 12, 2013 7:00:13 PM com.thalesgroup.hudson.plugins.xunit.service.XUnitService warningSystemLogger
WARNING: [xUnit] - The file 'C:\Programs\jenkins\jobs\Midas Testing\workspace\ssi\build\test-results\TEST-com.stottlerhenke.ssi.report.io.TestReportConfig.xml' is an invalid file.

Jun 12, 2013 7:00:13 PM com.thalesgroup.hudson.plugins.xunit.service.XUnitService errorSystemLogger

I am attaching a sample file that fails to validate with com.thalesgroup.dtkit.junit.model.JUnitModel.OUTPUT_JUNIT_6. Validating this file gives the following error:

At line 3 of file:///C:/Users/kmahan/Projects/JUnitTest/build/test-results/TEST-MyTest.xml:cvc-complex-type.2.4.b: The content of element 'properties' is not complete. One of '{"":property}' is expected.

My proposed fix would add minOccurs="0" to the properties element in junit-6.xsd (and possibly the other junit schemas as well?) to allow for empty properties elements.

Environment: Windows 7
Project: Jenkins
Labels: xunit testing plugin
Priority: Minor Minor
Reporter: Kyle Mahan
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply via email to