testsAndMisc/meta/scripts/lib
Krzysztof kuhy Rudnicki 170f843481
Some checks are pending
Pre-commit checks / pre-commit (push) Waiting to run
Shell tests / shell-tests (push) Waiting to run
Shell tests / arch-tests (push) Waiting to run
Make the jailed lib/tests gate able to fail, without breaking measurement
The jail recorded each case's exit code but reported only timeouts,
discarding every other non-zero status. A suite with a failing assertion
exited 0 through the push gate -- the same blind spot that let an earlier
session ship 2 failing assertions in the nc_php suite. Found by negative
control, not by reading: a deliberately failing assertion still exited 0.

Propagating that status unconditionally was wrong, and caught before landing:
the jail's own usage example passes a `bogus` case that exits non-zero to
cover an error path, so a clean 5/5 = 100.00% run started failing. That is
the mode the 105-lib campaign runs in.

So the behaviour sits behind --fail-on-case-error, default off, passed only
by ci_mirror.sh and shell-tests.yml. Verified in all four quadrants:
measurement + error case = 0, gate + error case = 1, gate + clean suite = 0,
gate + broken assertion = 1.

Both gates also pass --min 0: with no --measure the jail was measuring
run_all.sh itself against its default --min 100 and failing the push at
54.55%, a coverage verdict neither gate asked for. ci_mirror.sh now prints
the jail's output on failure, so a red gate can be diagnosed.

The added flag pushed the jail over the 250-line cap, so the in-namespace
case runner moved to lib/shell_coverage_case_runner.sh, following the
existing lib/shell_coverage_jail_setup.sh split. All four quadrants were
re-run after the extraction.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016sxxsDHWgdRhmdmzNMA6XM
2026-08-22 12:16:18 +02:00
..
disk_cleanup_common.sh Split disk_cleanup_check.sh: extract the helpers and the output blocks 2026-08-16 22:57:06 +02:00
shell_coverage_bar.sh Shell coverage: convert the ratchet to a measured 100% bar 2026-08-22 11:20:58 +02:00
shell_coverage_case_runner.sh Make the jailed lib/tests gate able to fail, without breaking measurement 2026-08-22 12:16:18 +02:00
shell_coverage_jail_setup.sh Cover nc_php.sh (98.82%) and teach the jail to measure foreign platforms 2026-08-22 11:30:32 +02:00
trace_prefix.sh Close three fail-open paths in the prefix trace harness 2026-08-16 23:38:38 +02:00
trace_stubs.sh Trace scripts that place files, via a prefix redirect 2026-08-16 23:31:49 +02:00