Sunday, March 20, 2016

RF test status and Testcase ID from output.xml file

import xml.etree.ElementTree as ET
root = ET.parse('output.xml').getroot()
for suites in root.findall('suite'):
    for test in suites.findall('test'):
        for status in test.findall('status'):
            print status.attrib['status'], test.attrib['id']