validate:launcher: Make failure as <failure> in our xunit reporter
authorThibault Saunier <tsaunier@igalia.com>
Thu, 6 Dec 2018 18:35:18 +0000 (15:35 -0300)
committerThibault Saunier <tsaunier@igalia.com>
Thu, 6 Dec 2018 18:51:43 +0000 (15:51 -0300)
I think it was a mistake to call them <error> as the two notions are
different (we marked failed test as "failures" in the <testuite> node).

Should make gitlab happy with our file!

validate/launcher/reporters.py

index 69f2d55..d3b6eaa 100644 (file)
@@ -209,8 +209,8 @@ class XunitReporter(Reporter):
                                self.encoding, 'replace')
         xml_file.write(self._forceUnicode(
             '<testcase classname=%(cls)s name=%(name)s time="%(taken).3f">'
-            '<error type=%(errtype)s message=%(message)s>%(stacktrace)s'
-            '</error>%(systemout)s</testcase>' %
+            '<failure type=%(errtype)s message=%(message)s>%(stacktrace)s'
+            '</failure>%(systemout)s</testcase>' %
             {'cls': self._quoteattr(test.get_classname()),
              'name': self._quoteattr(test.get_name()),
              'taken': test.time_taken,