build: adapt merge-junit-results to latest pytest/3 <testsuites> element
gitea/django-mellon/pipeline/head Build started... Details

This commit is contained in:
Frédéric Péters 2019-10-02 08:15:28 +02:00
parent bca13e37ef
commit 9da1c16c90
1 changed files with 2 additions and 0 deletions

View File

@ -36,6 +36,8 @@ def merge_results(xml_files):
for file_name in xml_files:
tree = ET.parse(file_name)
test_suite = tree.getroot()
if test_suite.tag == 'testsuites':
test_suite = test_suite.getchildren()[0]
failures += int(test_suite.attrib['failures'])
tests += int(test_suite.attrib['tests'])
errors += int(test_suite.attrib['errors'])