Skip to content

Commit

Permalink
fix(test): only check initial prefix for missing/extra resource names (
Browse files Browse the repository at this point in the history
  • Loading branch information
c-ryan-k authored Jan 15, 2025
1 parent 17d7c25 commit cc27768
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion azext_edge/tests/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,9 @@ def find_extra_or_missing_names(
ignore_missing: bool = False,
):
error_msg = []
# expected_names might contains descriptor, if so, remove it
# names may contain descriptors after the initial '.', just comparing first prefix
expected_names = [name.split(".")[0] for name in expected_names]
result_names = [name.split(".")[0] for name in result_names]
extra_names = [name for name in result_names if name not in expected_names]
if extra_names:
msg = f"Extra {resource_type} names: {', '.join(extra_names)}."
Expand Down

0 comments on commit cc27768

Please sign in to comment.