Skip to content

Commit

Permalink
tests: no need to run spread when there are not tests matching the fi…
Browse files Browse the repository at this point in the history
…lter (#14728)

This change is needed to avoid error in the ci when spread doesn't find
any test to run with the provided filter.
  • Loading branch information
sergiocazzolato authored Nov 15, 2024
1 parent ff9d91a commit eac2385
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/spread-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -210,10 +210,15 @@ jobs:
./tests/lib/spread/add-backend tests/lib/spread/backend.openstack.yaml spread.yaml
fi
# This coud be the case when either there are not systems for a group or
# This could be the case when either there are not systems for a group or
# the list of tests to run is empty
if [ -z "$RUN_TESTS" ]; then
echo "No tests to run, skiping..."
echo "No tests to run, exiting..."
exit 0
fi
if "$SPREAD" -list $RUN_TESTS 2>&1 | grep -q "nothing matches provider filter"; then
echo "No tests to run, exiting..."
exit 0
fi
Expand Down

0 comments on commit eac2385

Please sign in to comment.