Skip to content

Commit f72b79f

Browse files
Claudeclaude
andcommitted
CI - IMPROVEMENT - Narrow test triggering to an allowlist of tested paths
The detector matched any .jl file outside a denylist of docs, benchmarks and regression-harness. That meant new untested Julia triggered a full run unless someone remembered to extend the denylist: a benchmark, a root-level script, or a future tools/ directory all ran the suite for nothing. Replace it with an allowlist of what test/runtests.jl actually exercises: src/, test/, examples/, Project.toml, and this workflow. Untested code is now excluded by default rather than by maintenance. Kept as directory prefixes rather than *.jl: src/ForcingTerms/coil_geometries holds the .dat coil geometries the coil tests load, and test/test_data holds 28 non-Julia fixtures. Matching only *.jl would skip runs when either changes. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019tFBCa5iBXyb7xp8LxqBJx
1 parent fadb72d commit f72b79f

1 file changed

Lines changed: 9 additions & 7 deletions

File tree

.github/workflows/test.yaml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,15 @@ jobs:
5454
5555
files=$(gh api --paginate "repos/${REPO}/pulls/${PR_NUMBER}/files" --jq '.[].filename')
5656
57-
# Directories whose Julia sources are not exercised by test/runtests.jl.
58-
not_tested='^(docs|benchmarks|regression-harness)/'
59-
# Everything the test suite actually reads: sources, tests and their
60-
# fixtures, the example decks the tests run end-to-end, and this workflow.
61-
tested='(\.jl$|^Project\.toml$|^test/|^examples/|^\.github/workflows/test\.yaml$)'
62-
63-
relevant=$(printf '%s\n' "$files" | grep -Ev "$not_tested" | grep -E "$tested" || true)
57+
# Allowlist of what test/runtests.jl actually exercises: the package
58+
# itself, the tests and their fixtures, the example decks the tests run
59+
# end-to-end, the dependency set, and this workflow. Anything not listed
60+
# here does not trigger a run, so new untested Julia (benchmarks, docs
61+
# scripts, a future tools/ directory) is excluded by default rather than
62+
# by remembering to exclude it.
63+
tested='(^src/|^test/|^examples/|^Project\.toml$|^\.github/workflows/test\.yaml$)'
64+
65+
relevant=$(printf '%s\n' "$files" | grep -E "$tested" || true)
6466
6567
say "### Julia change detection"
6668
say ""

0 commit comments

Comments
 (0)