-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Attribute 'errors' must appear on element 'testsuite' #1777
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for pointing this out. Looks like we should use the XSD used by Maven Surefire. |
mpkorstanje
added a commit
that referenced
this issue
Sep 17, 2019
Cucumber JUnits xml format doesn't pass XSD validation in the Jenkins XUnit plugin because it is missing the errors attribute. Additionally time should be presented using numbers with both decimal and thousands separators. See: https://maven.apache.org/surefire/maven-surefire-plugin/xsd/surefire-test-report.xsd Closes #1777
6 tasks
mpkorstanje
added a commit
that referenced
this issue
Sep 22, 2019
Cucumber JUnits xml format doesn't pass XSD validation in the Jenkins XUnit plugin because it is missing the errors attribute. Additionally time should be presented using numbers with both decimal and thousands separators. See: https://maven.apache.org/surefire/maven-surefire-plugin/xsd/surefire-test-report.xsd Closes #1777
mpkorstanje
added a commit
that referenced
this issue
Sep 22, 2019
Cucumber JUnits xml format doesn't pass XSD validation in the Jenkins XUnit plugin because it is missing the errors attribute. Additionally time should be presented using numbers with both decimal and thousands separators. From: https://maven.apache.org/surefire/maven-surefire-plugin/xsd/surefire-test-report-3.0.xsd Via: https://maven.apache.org/surefire/maven-surefire-plugin/ Closes #1777
mpkorstanje
added a commit
that referenced
this issue
Sep 22, 2019
Cucumber JUnits xml format doesn't pass XSD validation in the Jenkins XUnit plugin because it is missing the errors attribute. Additionally time should be presented using numbers with both decimal and thousands separators. From: https://maven.apache.org/surefire/maven-surefire-plugin/xsd/surefire-test-report-3.0.xsd Via: https://maven.apache.org/surefire/maven-surefire-plugin/ Closes #1777
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
I'm trying to configure Publish xUnit test result report in Jenkins and faced with problems of format differences.
To Reproduce
Steps to reproduce the behavior:
--plugin
junit:${project.build.directory}/cucumber-results.xml
(cucumber-core v.4.7.2 is used, so cucumber.runtime.formatter.JUnitFormatter is used in it)
WARNING: The file '.../target/cucumber-results.xml' is an invalid file. WARNING: At line 2 of file: .../target/cucumber-results.xml:cvc-pattern-valid: Value '110.107047' is not facet-valid with respect to pattern '(([0-9]{0,3},)*[0-9]{3}|[0-9]{0,3})*(\.[0-9]{0,3})?' for type 'SUREFIRE_TIME'. WARNING: At line 2 of file:.../target/cucumber-results.xml:cvc-attribute.3: The value '110.107047' of attribute 'time' on element 'testsuite' is not valid with respect to its type, 'SUREFIRE_TIME'. WARNING: At line 2 of file:.../target/cucumber-results.xml:cvc-complex-type.4: Attribute 'errors' must appear on element 'testsuite'. WARNING: The result file '.../target/cucumber-results.xml' for the metric 'JUnit' is not valid. The result file has been skipped. INFO: Skipping tests recording.
Expected behavior
No parce problems occure
Context & Motivation
Was trying to do an integration with Slack notification from Jenkins. Plugin could send to Slack from Jenkins list with names of failed tests. But to work correct, xml report needed. So step "Publish xUnit test result report" is needed.
Your Environment
Additional context
Workaround could be done by using Custom tool with providing valid XSL template.
The text was updated successfully, but these errors were encountered: