Skip to content

Commit

Permalink
src/send_kcidb: send tests only if KCIDB test mapping exists
Browse files Browse the repository at this point in the history
All test suite definitions must have `kcidb_test_suite`
property i.e. KCIDB test suite mapping.
Only send tests for those the mapping is found.

Signed-off-by: Jeny Sadadia <[email protected]>
  • Loading branch information
Jeny Sadadia authored and JenySadadia committed Jun 12, 2024
1 parent 1231d6c commit ba68789
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/send_kcidb.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,10 @@ def _parse_node_path(self, path, is_checkout_child):
suite_name = self._jobs[sub_path].kcidb_test_suite
if suite_name:
new_path.append(suite_name)
else:
self.log.error(f"KCIDB test suite mapping not found for \
the test: {sub_path}")
return None
else:
new_path.append(sub_path)
# Handle path such as ['tast-ui-x86-intel', 'tast', 'os-release'] converted
Expand Down Expand Up @@ -359,6 +363,9 @@ def _get_test_data(self, node, origin,
test_node, build_node = self._parse_test_node(
origin, node
)
if not test_node['path']:
self.log.info(f"Not sending test as path information is missing: {test_node['id']}")
return
parsed_test_node.append(test_node)
if build_node:
parsed_build_node.append(build_node)
Expand Down

0 comments on commit ba68789

Please sign in to comment.