Skip to content

ci: extract the shell-suite runner and guard that CI keeps calling it - #127

Merged
laird merged 1 commit into
masterfrom
fix/119-shell-suite-runner
Aug 17, 2026
Merged

ci: extract the shell-suite runner and guard that CI keeps calling it#127
laird merged 1 commit into
masterfrom
fix/119-shell-suite-runner

Conversation

@laird

@laird laird commented Aug 17, 2026

Copy link
Copy Markdown
Owner

Supersedes #119, which carried this fix 26 commits behind master (CONFLICTING) with unrelated already-landed history. Reapplies the one real commit cleanly.

Scope

Not a fix for #32 -- that's already fixed on master (inline loop in the shell job). This closes what the inline fix left open: the loop was reachable only by pushing, and nothing asserted CI kept calling it.

Changes

  • scripts/run-shell-suites.sh -- the inline loop, extracted, so CI and a local run execute the same code.
  • .github/workflows/test.yml -- the shell job's inline script becomes run: bash scripts/run-shell-suites.sh.
  • tests/test_ci_runs_shell_suites.py -- 8 pytest tests guarding the workflow and the runner.

Verified the guard actually fails, not just exists

Temporarily replaced the workflow step with a no-op and confirmed test_ci_invokes_the_shell_runner goes red, then restored it.

One correction to the ported original

Master gained tests/run-shell-suite.sh (a meta-runner that loops over every test_*.sh and prints one aggregate summary for regression-test.sh's parser) after PR #119 was opened. The original tests/*.sh glob would pick that file up as a leaf suite, running everything a second time nested inside it on every CI run. Narrowed the glob to tests/test_*.sh, which excludes it structurally, and added test_runner_excludes_the_meta_runner pinning the intent.

Verification

$ uv run --with pytest python -m pytest tests/test_ci_runs_shell_suites.py -v
8 passed
$ bash scripts/run-shell-suites.sh
Shell suites: 23 passed, 1 failed, 0 skipped
Failed:
  - tests/test_mux_send_enter.sh

The one failure is pre-existing on master, unrelated to this change (tracked as #125).

Issue #32 (CI collecting only pytest, so tests/*.sh went unexecuted) was
already fixed on master by inlining a loop into the shell job of
.github/workflows/test.yml. Two gaps remained: the loop was reachable only
by pushing (no local equivalent), and nothing asserted CI kept calling it --
deleting the step would silently restore the original silence.

Extracts the loop to scripts/run-shell-suites.sh, so CI and a local run
execute identical code, and adds tests/test_ci_runs_shell_suites.py (pytest,
so the guard itself is guaranteed to run) asserting the workflow still
invokes it and still runs pytest, that the runner covers every suite and
accumulates rather than short-circuits on failure, and that a deliberately
failing suite makes it exit non-zero.

Verified the guard actually fails, not just that it exists: temporarily
replaced the workflow's `bash scripts/run-shell-suites.sh` step with a no-op
and confirmed test_ci_invokes_the_shell_runner goes red, then restored it.

One correction to the ported original: master gained tests/run-shell-suite.sh
(a meta-runner that loops over every test_*.sh and prints one aggregate
summary for regression-test.sh's parser) after this PR was opened. The
runner's original tests/*.sh glob would have picked that file up as if it
were a leaf suite, running everything a second time nested inside it every
CI run. Narrowed the glob to tests/test_*.sh, which the meta-runner's name
doesn't match, and added a test pinning that exclusion so a future rename
can't quietly reintroduce the nesting.

Reapplies the one real commit from PR #119, which carried this fix 26
commits behind master (CONFLICTING) with unrelated already-landed history.
@laird
laird merged commit 9bafa4d into master Aug 17, 2026
2 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant