job4: SPEC-10 decisions-snapshot-fixture

New lib/tests/fixtures/decisions-snapshot.md (neutral name, LRN-077
style): carries a --help token (so reconcile_contradiction_candidates
still surfaces the BDR-001 ⇄ --help-chantier candidate against
todo-snapshot.md), a "one-line ticket" line, and representative
OUT-OF-SCOPE/DEFERRED/follow-up context. T3 and T5 in run-reconcile.sh
now read this fixture instead of the LIVE $MEM/decisions.md; deleted
the $MEM variable definition and its stale comment. Closes J4-10
(FIXTURE-DRIFT): T3/T5 were the last live-registry reads in this
suite (T2 was fixed in job3-B1) — any legitimate prune/reword of the
real decisions.md would have reded the suite for a reason unrelated
to the reconcile engine itself.

grep -c '$MEM' lib/tests/run-reconcile.sh == 0 (verified).
GREEN: real repo, 26/26 passed (all 4 T3 markers + T5 candidate found
via the fixture).
Red demo (per spec — no code mutation, this is a fixture-substitution
spec): lean scratch copy, pointed T3's decisions-arg at /dev/null
transiently → "one-line ticket" (the only marker living solely in the
decisions-side fixture, not in todo-snapshot.md) goes missing, RED;
the other 3 markers stay green (satisfied by todo-snapshot.md alone).
Proves the assertions actually read the fixture rather than passing
vacuously.
This commit is contained in:
Bastien Chanot
2026-07-06 19:16:04 +02:00
parent 12c0d1d9fd
commit fb749f4e30
2 changed files with 25 additions and 5 deletions
+21
View File
@@ -0,0 +1,21 @@
# decisions-snapshot — frozen fixture for run-reconcile.sh T3/T5 (SPEC-10, J4-10)
# Neutral name, LRN-077 style: this is NOT the live registry. Carries exactly what
# reconcile_deferrals / reconcile_contradiction_candidates scan against
# fixtures/todo-snapshot.md, so the suite never reds just because the live
# decisions.md gets legitimately pruned or reworded.
## BDR-900 — Uniform --help helper via session-start hook (option C)
- **Decision**: every skill expose `--help` via a shared snippet injected by a
hook, not a duplicate helper per SKILL.md.
- **Status**: accepted · won't-build — measured non-rentable, see the linked
TODO chantier (the intended behavior was already spontaneous).
- **Follow-up**: OUT-OF-SCOPE for now; reconsider only if a new skill class
demonstrably needs a diverging `--help` shape.
## BDR-901 — rename-note follow-up
- Bigger picture: looks like a deliberate rename to disambiguate two
same-named things. Could be a planned migration that stalled. Worth a
one-line ticket separate from the main chantier.
## BDR-902 — deferred cleanup
- DEFERRED until the next audit pass; not actionable now.
+4 -5
View File
@@ -11,7 +11,6 @@ GREP=/usr/bin/grep # LRN-074: pin grep
HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
REPO="$(cd "$HERE/.." && pwd)"
FIX="$HERE/fixtures"
MEM="$REPO/../.claude/memory"; [ -d "$MEM" ] || MEM="$REPO/.claude/memory"
# shellcheck source=/dev/null
source "$REPO/reconcile.sh"
@@ -47,7 +46,7 @@ open_ids=$(reconcile_blk_open "$b" | cut -f1 | sort | tr '\n' ' ')
if [ "$open_ids" = "BLK-001 BLK-003 " ]; then ok "T2c open blockers = {001,003}"; else no "T2c open = [$open_ids], expected {001,003}"; fi
echo; echo "=== T3 deferral lexical sweep (HONEST LIMIT: marked-only) ==="
defer=$(reconcile_deferrals "$FIX/todo-snapshot.md" "$MEM/decisions.md")
defer=$(reconcile_deferrals "$FIX/todo-snapshot.md" "$FIX/decisions-snapshot.md")
for mark in "OUT-OF-SCOPE" "DEFERRED" "follow-up" "one-line ticket"; do
if has "$defer" "$mark"; then ok "T3 found marked deferral: $mark"; else no "T3 missed marker: $mark"; fi
done
@@ -63,15 +62,15 @@ if [ "$truths" -ge 6 ]; then ok "T4e snapshot supplies $truths real-true facts
echo " (7th cat-4 item — twin doc-sync [~] cross-ref — is SURFACED for review, not auto-verified: honest limit)"
echo; echo "=== T5 contradiction candidates (surface, never assert) ==="
cand=$(reconcile_contradiction_candidates "$MEM/decisions.md" "$FIX/todo-snapshot.md")
cand=$(reconcile_contradiction_candidates "$FIX/decisions-snapshot.md" "$FIX/todo-snapshot.md")
if has "$cand" "--help"; then ok "T5 surfaced --help candidate (BDR-001 ⇄ --help chantier)"; else no "T5 missed --help candidate"; fi
echo; echo "=== T6 live oracle smoke — oracles QUERY real git/fs (not a name) ==="
if reconcile_oracle_merge_done "$REPO" "prune-memory"; then ok "T6a merge_done(prune-memory) via git log"; else no "T6a merge not found in git"; fi
if reconcile_oracle_sha_exists "$REPO" "be1dcef"; then ok "T6b sha_exists(be1dcef) via cat-file"; else no "T6b sha missing"; fi
# $REPO here = lib/ (see line 12) → lib/../skills = the real skills/ dir.
# Was "$MEM/../skills" = .claude/skills/ — the LRN-042 parasite dir, removed
# 2026-06-30 by make plugin Step 8.5: green-for-wrong-reason (LRN-077 class).
# Was .claude/skills/ — the LRN-042 parasite dir, removed 2026-06-30 by
# make plugin Step 8.5: green-for-wrong-reason (LRN-077 class).
dk="$REPO/../skills/darwin-skill"
if reconcile_oracle_path_present "$dk"; then ok "T6c path_present(darwin-skill) via fs"; else no "T6c path absent"; fi