mesonbuild/mtest.py: filter more invalid googletest JUnit4 attributes

googletest 1.12.1 generates new JUnit4 invalid attributes file and
line.

Maybe all gtest "invalid" attributes are actually valid JUnit5
attributes, and maybe schema should be upgraded to JUni5.

Signed-off-by: Dimitri John Ledkov <dimitri.ledkov@canonical.com>
pull/9372/merge
Dimitri John Ledkov 2 years ago committed by Jussi Pakkanen
parent 28d07c31b8
commit c3cc66a1cc
  1. 4
      mesonbuild/mtest.py

@ -775,6 +775,10 @@ class JunitBuilder(TestLogger):
del case.attrib['result']
for case in suite.findall('.//testcase[@timestamp]'):
del case.attrib['timestamp']
for case in suite.findall('.//testcase[@file]'):
del case.attrib['file']
for case in suite.findall('.//testcase[@line]'):
del case.attrib['line']
self.root.append(suite)
return

Loading…
Cancel
Save