diff --git a/bin/tests/convert-trs-to-junit.py b/bin/tests/convert-trs-to-junit.py index fdfd8cf3ce..927506a827 100755 --- a/bin/tests/convert-trs-to-junit.py +++ b/bin/tests/convert-trs-to-junit.py @@ -65,7 +65,13 @@ def walk_trss(source_dir): full_trs_path = os.path.join(cur_dir, filename) full_log_path = os.path.join(cur_dir, log_name) sub_dir = os.path.relpath(cur_dir, source_dir) - test_name = os.path.join(sub_dir, filename_prefix) + test_dir_path = os.path.join(sub_dir, filename_prefix) + + if sub_dir.startswith("bin/tests/system"): + # Match the `pytest` style test names for system tests + test_name = f"test_{filename_prefix}" + else: + test_name = test_dir_path t = { "name": test_name, @@ -76,7 +82,7 @@ def walk_trss(source_dir): # try to find dir/file path for a clickable link try: - t["rel_file_path"] = find_test_relative_path(source_dir, test_name) + t["rel_file_path"] = find_test_relative_path(source_dir, test_dir_path) except KeyError: pass # no existing path found