-
Notifications
You must be signed in to change notification settings - Fork 71
Description
In the spread.yaml workflow line 65, a regex is used to prevent duplicated tests being passed to the spread command.
However, this regex gives false negatives in certain scenarios:
Suppose the changed files include slices/golang-1.22-go.yaml and tests/spread/integration/golang/task.yaml.
The variable $spread_tasks will be filled with lxd:tests/spread/integration/golang-1.22-go. When tests/spread/integration/golang is taken in to the expression $spread_tasks != *"${pkg_tests}"*, it evaluates to false, since lxd:tests/spread/integration/golang-1.22-go equals to the pattern *tests/spread/integration/golang*.
In this case, although changes are made to tests/spread/integration/golang/task.yaml, the tests won't never run, since lxd:tests/spread/integration/golang-1.22-go takes the precedence.
A workflow run can also prove this behaviour.