Created
January 28, 2019 15:53
-
-
Save adiralashiva8/78fec0912499718d43b565f875d3081c to your computer and use it in GitHub Desktop.
Robotframework: Get test case statistics by parsing output.xml using robot.result package (api)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from robot.api import ExecutionResult, ResultVisitor | |
result = ExecutionResult("output.xml") | |
stats = result.statistics | |
total_tests= stats.total.all.total | |
passed_tests= stats.total.all.passed | |
failed_tests= stats.total.all.failed | |
print total_tests | |
print passed_tests | |
print failed_tests |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment