---
phase: 7
slug: workflow-smoke-convention-locks
status: draft
nyquist_compliant: false
wave_0_complete: false
created: 2026-05-20
---

# Phase 7 — Validation Strategy

> Per-phase validation contract for feedback sampling during execution.

---

## Test Infrastructure

| Property | Value |
|----------|-------|
| **Framework** | vitest 1.x (apps/client + packages/game-logic) + node:test for tools/ scripts |
| **Config file** | apps/client/vitest.config.ts, packages/game-logic/vitest.config.ts; tools/scripts/*.mjs scripts are exit-code-checked directly |
| **Quick run command** | `pnpm preflight` |
| **Full suite command** | `pnpm preflight && pnpm -r test` |
| **Estimated runtime** | ~30s (preflight) + ~60s (workspace tests) |

---

## Sampling Rate

- **After every task commit:** Run `pnpm preflight` (the script under construction — must exit 0 once each preflight step lands)
- **After every plan wave:** Run `pnpm preflight && pnpm -r test`
- **Before `/gsd:verify-work`:** Full suite green + `pnpm trace:check` green + ADR lint green for 0009/0010/0011/0012
- **Max feedback latency:** ~90s

---

## Per-Task Verification Map

> Per-task IDs locked at plan time. Skeleton table; planner fills exact task IDs + commands.

| Task ID | Plan | Wave | Requirement | Threat Ref | Secure Behavior | Test Type | Automated Command | File Exists | Status |
|---------|------|------|-------------|------------|-----------------|-----------|-------------------|-------------|--------|
| 7-ADR0009-* | ADR-0009 | 1 | MAP-02 | — | gridSize=4 unified documented; ADR lints clean | doc-lint | `node tools/asset-catalog/scripts/lint-adr.mjs docs/adr/0009-ldtk-gridsize-convention.md` | ❌ W0 | ⬜ pending |
| 7-ADR0010-* | ADR-0010 | 1 | MAP-02 | — | sidecar JSON carrier documented; ADR lints clean | doc-lint | `node tools/asset-catalog/scripts/lint-adr.mjs docs/adr/0010-ldtk-tileset-source-hash.md` | ❌ W0 | ⬜ pending |
| 7-ADR0011-* | ADR-0011 | 1 | MAP-02 | — | 3×3 GridVania chunk grid documented; chunk dims sum to 8000×6400 + multiple of 4 | doc-lint | `node tools/asset-catalog/scripts/lint-adr.mjs docs/adr/0011-bncentral-gridvania-chunking.md` | ❌ W0 | ⬜ pending |
| 7-ADR0012-* | ADR-0012 | 1 | MAP-02 | — | Pin file + operator-trust posture documented | doc-lint + file-exists | `node tools/asset-catalog/scripts/lint-adr.mjs docs/adr/0012-ldtk-version-pin.md && test -s tools/ldtk-version.txt` | ❌ W0 | ⬜ pending |
| 7-HYG02-* | HYG-02 | 2 | HYG-02 | — | Drift-lock script exits non-zero on any REQ-*-XX placeholder under scan roots | unit | `node tools/scripts/lint-no-req-placeholders.mjs` | ❌ W0 | ⬜ pending |
| 7-ATLAS-HASH-STUB-* | preflight | 2 | MAP-15 | — | `lint:atlas-hash` exits 0 when `maps/` is empty; non-zero when sha mismatch in fixture | unit | `node tools/scripts/lint-atlas-hash.mjs` | ❌ W0 | ⬜ pending |
| 7-CONVREG-STUB-* | preflight | 2 | MAP-15 | — | `check:conversion-regression` stub logs `skipped: pending Phase 9` and exits 0 | unit | `node tools/scripts/check-conversion-regression.mjs` | ❌ W0 | ⬜ pending |
| 7-PREFLIGHT-* | preflight | 3 | MAP-15, HYG-01 | — | `pnpm preflight` chains all 7 steps fail-fast; exits 0 on green repo state | int | `pnpm preflight` | ❌ W0 | ⬜ pending |
| 7-LOCAL-DEPLOY-DOCS-* | docs | 3 | MAP-15 | — | `docs/deploy/LOCAL-DEPLOY.md` contains `## Preflight gate (MANDATORY)` above deploy steps | doc-grep | `grep -q "## Preflight gate (MANDATORY)" docs/deploy/LOCAL-DEPLOY.md` | ❌ W0 | ⬜ pending |
| 7-TRACE-EXTEND-* | traceable-reqs | 1 | MAP-02 | — | `traceable-reqs.toml` contains 18 new v1.1 entries (MAP-01..16 + HYG-01..02); `pnpm trace:check` passes | int | `pnpm trace:check` | ❌ W0 | ⬜ pending |
| 7-SMOKE-* | smoke | 4 | MAP-02 | — | `maps/_smoke/synth-8000x6400.ldtk` matches 3×3 GridVania chunk dims per ADR 0011; SMOKE-NOTES.md PASS/FAIL recorded | manual | manual operator screenshot + notes | ❌ W0 | ⬜ pending |

*Status: ⬜ pending · ✅ green · ❌ red · ⚠️ flaky*

---

## Wave 0 Requirements

- [ ] `tools/scripts/lint-no-req-placeholders.mjs` — net-new script, ~10–25 LOC, MUST land before preflight wiring step
- [ ] `tools/scripts/lint-atlas-hash.mjs` — stub script; no-op when `maps/` empty, throws on sha mismatch fixture
- [ ] `tools/scripts/check-conversion-regression.mjs` — stub; logs `skipped: pending Phase 9`, exits 0
- [ ] `tools/ldtk-version.txt` — single-line file (`1.5.3`) before LDtk version preflight step
- [ ] `package.json` entries: `preflight`, `lint:no-req-placeholders`, `lint:atlas-hash`, `lint:adr:0009`..`lint:adr:0012` — script names referenced in this VALIDATION.md must exist before tasks reference them

*Existing infrastructure (`tooling/no-inline-origin.ts`, `pnpm lint:room-layout`, `pnpm trace:check`, `tools/asset-catalog/scripts/lint-adr.mjs`) is reused as-is — no Wave 0 install.*

---

## Manual-Only Verifications

| Behavior | Requirement | Why Manual | Test Instructions |
|----------|-------------|------------|-------------------|
| Operator BNCentral-sized chunked authoring smoke test (PASS/FAIL + screenshot) | MAP-02 (Success Criterion 5) | LDtk is a desktop GUI; no headless harness; "tolerable" is qualitative per D-23 | Operator opens `maps/_smoke/synth-8000x6400.ldtk` in LDtk 1.5.3, authors all 9 chunks with BORDERED floor tiles only, opens+saves at minimum center + one corner + one edge, records subjective lag impressions + screenshot in `SMOKE-NOTES.md` |
| LDtk version pin file matches the operator-installed LDtk app version | MAP-02 (D-12) | LDtk is a desktop GUI with no stable CLI/registry surface on Windows; operator-trust posture | Operator confirms `tools/ldtk-version.txt` content matches the LDtk About dialog version at the time of authoring |

---

## Validation Sign-Off

- [ ] All tasks have `<automated>` verify or Wave 0 dependencies (smoke + version-pin are manual-only, documented above)
- [ ] Sampling continuity: no 3 consecutive tasks without automated verify
- [ ] Wave 0 covers all MISSING references (stub scripts, pin file, package.json wiring)
- [ ] No watch-mode flags
- [ ] Feedback latency < 90s
- [ ] `nyquist_compliant: true` set in frontmatter

**Approval:** pending
