(a) import-resolve: 9 OUTSIDE_REPO faults -> 0 over 138 graded files. The eight
lanes' test files now insert str(Path(__file__).resolve().parent) and resolve
their data paths from __file__; test_hermes.py is rewritten as the host probe it
always was (skills root from HERMES_SKILLS_DIR/HERMES_HOME/~/.hermes/skills, rc 0
found / 77 SKIP / 1 FAIL) instead of binding a module that does not exist.
Falsified: poisoning the repo copy reds the rebound test (rc 1) and leaves HEAD's
host-bound copy green (rc 0), both restored.
(b) path-claims: 225 new -> 0. All 225 came from sol's untracked-file census; each
was measured (0 add-commits on any ref, present on disk untracked, listed verbatim
in the census) and is a NOT_ADDED row under a batch note. One CLEARED row dropped
(spark/lwc_counter.py, resurrected at 3e667eb after Q125 retired it).
Carried in, not authored here: tools/verify.py's ninth leg and the two-line Q98
record (Sentinel's Q98 artifact), so HEAD agrees with Q98's own text.
verify --repo .: 9 legs, 9 pass, 0 fault -- gate OK. Report:
/root/.hermes/wizard-outputs/volt/2026-10-30-q126.md
38 lines
1.8 KiB
Bash
Executable File
38 lines
1.8 KiB
Bash
Executable File
#!/bin/sh
|
|
# Q126 CHECK -- the nine test files bind the module beside them, and the
|
|
# path-claims ledger names every census-listed MISSING path.
|
|
# rc 0 = import-resolve 0 faults, path-claims 0 new, all nine files green.
|
|
set -u
|
|
REPO="$(cd "$(dirname "$0")/../.." && pwd)"
|
|
cd "$REPO" || exit 2
|
|
|
|
# (a) no committed test file binds a module to a path outside the repo
|
|
python3 tools/import_resolve_check.py --repo . --rev WORKTREE --quiet || exit 1
|
|
|
|
# (b) every MISSING path the census produces is named in the ledger
|
|
OUT="${TMPDIR:-/tmp}/q126-pathclaims.$$"
|
|
python3 tools/path_claim_check.py --repo . --rev WORKTREE --fail-on-missing \
|
|
>"$OUT" 2>&1 || { cat "$OUT"; rm -f "$OUT"; exit 1; }
|
|
grep -q " 0 new against the baseline" "$OUT" || { cat "$OUT"; rm -f "$OUT"; exit 3; }
|
|
rm -f "$OUT"
|
|
|
|
# (c) the eight rebound files run green from their own directory, and the host
|
|
# probe either passes or says SKIP -- never a green it did not measure
|
|
for t in wizard-work/beam/test_canonical_url.py wizard-work/beam/test_median.py \
|
|
wizard-work/spark/test_array_intersection.py \
|
|
wizard-work/spark/test_counter_util.py \
|
|
wizard-work/spark/test_email_validator.py \
|
|
wizard-work/spark/test_prime_factorizer.py \
|
|
wizard-work/spark/test_url_title_extractor.py \
|
|
wizard-work/spark/test_validator.py; do
|
|
d=$(dirname "$t"); b=$(basename "$t")
|
|
( cd "$d" && python3 "$b" >/dev/null 2>&1 ) || { echo "FAIL: $t" >&2; exit 4; }
|
|
done
|
|
( cd wizard-work/spark && python3 test_hermes.py >"${OUT}.hermes" 2>&1 )
|
|
rc=$?
|
|
grep -qE "^(PASS|SKIP):" "${OUT}.hermes" || { cat "${OUT}.hermes"; rm -f "${OUT}.hermes"; exit 5; }
|
|
rm -f "${OUT}.hermes"
|
|
[ "$rc" = 0 ] || [ "$rc" = 77 ] || { echo "FAIL: test_hermes.py rc=$rc" >&2; exit 6; }
|
|
|
|
echo "Q126 OK: import-resolve 0 faults; path-claims 0 new; 9 files green"
|