fix(e2e): point the selector's suite rule back at the allowlist rule

The first commit says the two rules are cross-referenced so they move
together, but only lg_suite_has_test pointed at the selector. The
selector's suite enumeration comment now names lg_suite_has_test as well,
so a change to either side prompts the other.

The layout case also pins a chainsaw-test.yml that is a directory, the
other half of the type test: dropping that name from the find now turns
the case red.

Signed-off-by: Marian Koreniuk <moriarti@cp.if.ua>
Assisted-by: LLM
(cherry picked from commit b61ad29783)
Signed-off-by: cozystack-ci[bot] <274107086+cozystack-ci[bot]@users.noreply.github.com>
This commit is contained in:
Marian Koreniuk authored and Myasnikov Daniil committed 2026-11-10 12:23:21 +00:00
1 parent 10d1e7d286
commit 7ec550b7b8
2 files changed
+5 -3

No files matched your search

+3 -3
View File
@@ -439,16 +439,16 @@ baseline_of_platform() {
# Chainsaw finds a Test: chainsaw-test.yaml, chainsaw-test.yml, numbered step
# files, or a Test nested in a subdirectory. The allowlist has to accept the
# same set, or a suite that runs cannot be exempted and the run stops before
# the first suite. That includes a chainsaw-test.yaml that is a directory:
# the first suite. That includes a chainsaw-test.y*ml that is a directory:
# the selector keeps it so Chainsaw fails on it loudly, and refusing it here
# would stop the run before Chainsaw could report it.
new_fixture
mkdir -p "$FIX/root/plain" "$FIX/root/yml" "$FIX/root/steps" "$FIX/root/nested/sub" "$FIX/root/dirtest/chainsaw-test.yaml"
mkdir -p "$FIX/root/plain" "$FIX/root/yml" "$FIX/root/steps" "$FIX/root/nested/sub" "$FIX/root/dirtest/chainsaw-test.yaml" "$FIX/root/dirtestyml/chainsaw-test.yml"
: >"$FIX/root/plain/chainsaw-test.yaml"
: >"$FIX/root/yml/chainsaw-test.yml"
: >"$FIX/root/steps/01-install.yaml"
: >"$FIX/root/nested/sub/chainsaw-test.yaml"
printf 'plain cozystack/cozystack#1\nyml cozystack/cozystack#1\nsteps cozystack/cozystack#1\nnested cozystack/cozystack#1\ndirtest cozystack/cozystack#1\n' >"$FIX/allow"
printf 'plain cozystack/cozystack#1\nyml cozystack/cozystack#1\nsteps cozystack/cozystack#1\nnested cozystack/cozystack#1\ndirtest cozystack/cozystack#1\ndirtestyml cozystack/cozystack#1\n' >"$FIX/allow"
lg lg_allowlist_validate "$FIX/allow" "$FIX/root"
rm -rf "$FIX"
}
+2
View File
@@ -178,6 +178,8 @@ inert_config_pattern='^(examples/|\.github/|\.claude/|\.gemini/|img/|hack/testda
# and `-type f` would be too narrow. A chainsaw-test.y*ml counts whatever its
# type: Chainsaw stats it and fails loudly on a directory, and leaving that
# suite out would hide the failure instead.
# The leak guard's allowlist accepts a suite by the same rule, in
# lg_suite_has_test (hack/e2e-chainsaw/_lib/leak-guard.sh). Change both together.
#
# Captured before the sed/sort rather than piped straight into them: a pipeline
# carries its LAST command's status, so `$(find ... | sed | sort)` would report