summaryrefslogtreecommitdiff
path: root/templates/reports/junit.xml
diff options
context:
space:
mode:
Diffstat (limited to 'templates/reports/junit.xml')
-rw-r--r--templates/reports/junit.xml51
1 files changed, 51 insertions, 0 deletions
diff --git a/templates/reports/junit.xml b/templates/reports/junit.xml
new file mode 100644
index 0000000000..fe2566bd42
--- /dev/null
+++ b/templates/reports/junit.xml
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ This file has been modeled after the basic
+ specifications at this url:
+
+ http://help.catchsoftware.com/display/ET/JUnit+Format
+-->
+<testsuites>
+{% for suite in test_suites %}
+ <testsuite name="{{ suite.name }}"
+ errors="{{ suite.nerrors }}"
+ tests="{{ suite.ntests }}"
+ failures="{{ suite.nfailures }}"
+ time="{{ suite.time }}"
+ timestamp="{{ suite.timestamp }}" >
+ <properties>
+{% for property in suite.properties %}
+ <property name="{{ property.name }}" value="{{ property.value }}" />
+{% endfor %}
+ </properties>
+{% for test in suite.testcases %}
+ <testcase classname="{{ test.name }}"
+ name="{{ test.id }}"
+ time="{{ test.elapsed_time }}">
+{% if test.result == 'failure' %}
+ <failure message="{{ test.message }}">
+{{ test.exception }}
+ </failure>
+{% elif test.result == 'error' %}
+ <error message="{{ test.message }}">
+{{ test.exception }}
+ </error>
+{% elif test.result == 'skipped' %}
+ <skipped />
+{% endif %}
+{% if test.stdout %}
+ <system-out>
+{{ test.stdout }}
+ </system-out>
+{% endif %}
+{% if test.stderr %}
+ <system-err>
+{{ test.stderr }}
+ </system-err>
+{% endif %}
+ </testcase>
+{% endfor %}
+{# Add an error tag? #}
+ </testsuite>
+{% endfor %}
+</testsuites>