build: adapt merge-junit-results to latest pytest/3 <testsuites> element
This commit is contained in:
parent
487229c96b
commit
325ec83617
|
@ -36,6 +36,8 @@ def merge_results(xml_files):
|
||||||
for file_name in xml_files:
|
for file_name in xml_files:
|
||||||
tree = ET.parse(file_name)
|
tree = ET.parse(file_name)
|
||||||
test_suite = tree.getroot()
|
test_suite = tree.getroot()
|
||||||
|
if test_suite.tag == 'testsuites':
|
||||||
|
test_suite = test_suite.getchildren()[0]
|
||||||
failures += int(test_suite.attrib['failures'])
|
failures += int(test_suite.attrib['failures'])
|
||||||
tests += int(test_suite.attrib['tests'])
|
tests += int(test_suite.attrib['tests'])
|
||||||
errors += int(test_suite.attrib['errors'])
|
errors += int(test_suite.attrib['errors'])
|
||||||
|
|
Loading…
Reference in New Issue