Skip to content

Commit

Permalink
Leave test.valid_systems alone if it has length 0
Browse files Browse the repository at this point in the history
  • Loading branch information
Caspar van Leeuwen committed Feb 13, 2024
1 parent 9667d7e commit b748594
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions eessi/testsuite/hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -298,9 +298,10 @@ def _set_or_append_valid_systems(test: rfm.RegressionTest, valid_systems: str):

# test.valid_systems wasn't set yet, so set it
if len(test.valid_systems) == 0:
test.valid_systems = [valid_systems]
# test.valid_systems is empty, meaning all tests are filtered out. This hook shouldn't change that
pass
# test.valid_systems still at default value, so overwrite
elif len(test.valid_systems) == 1 and test.valid_systems[0] == '*':
elif len(test.valid_systems) == 1 and test.valid_systems[0] == '*':
test.valid_systems = [valid_systems]
# test.valid_systems was set before, so append
elif len(test.valid_systems) == 1:
Expand Down

0 comments on commit b748594

Please sign in to comment.