mirror of
https://git.yoctoproject.org/poky
synced 2026-05-08 05:09:24 +00:00
resulttool: Add support to create test report in JUnit XML format
This adds the functionality to convert the results of the testresults.json file to a unit test report in JUnit XML format. The unit test report can be used in the CI/CD pipeline to display the test results. To use the resulttool scripts, first source oe environment, then run the entry point script to look for help. $ resulttool To generate the unit test report, execute the below $ resulttool junit <json_file> By default the unit test report is stored as <build_dir>/tmp/log/oeqa/junit.xml. (From OE-Core rev: 3f9be03946243feaa09b908d7010899769091fe6) Signed-off-by: Clara Kowalsky <clara.kowalsky@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
f4f9ebf6fb
commit
5aeabd3217
@@ -15,6 +15,9 @@
|
||||
# To report test report, execute the below
|
||||
# $ resulttool report <source_dir>
|
||||
#
|
||||
# To create a unit test report in JUnit XML format, execute the below
|
||||
# $ resulttool junit <json_file>
|
||||
#
|
||||
# To perform regression file analysis, execute the below
|
||||
# $ resulttool regression-file <base_result_file> <target_result_file>
|
||||
#
|
||||
@@ -43,6 +46,7 @@ import resulttool.regression
|
||||
import resulttool.report
|
||||
import resulttool.manualexecution
|
||||
import resulttool.log
|
||||
import resulttool.junit
|
||||
logger = scriptutils.logger_create('resulttool')
|
||||
|
||||
def main():
|
||||
@@ -61,6 +65,7 @@ def main():
|
||||
resulttool.regression.register_commands(subparsers)
|
||||
resulttool.report.register_commands(subparsers)
|
||||
resulttool.log.register_commands(subparsers)
|
||||
resulttool.junit.register_commands(subparsers)
|
||||
|
||||
args = parser.parse_args()
|
||||
if args.debug:
|
||||
|
||||
Reference in New Issue
Block a user