--- phase: 5 slug: tech-debt status: draft nyquist_compliant: false wave_0_complete: false created: 2026-03-30 --- # Phase 5 — Validation Strategy > Per-phase validation contract for feedback sampling during execution. --- ## Test Infrastructure | Property | Value | |----------|-------| | **Framework** | Vitest 4.1.1 | | **Config file** | `vitest.config.ts` (root) | | **Quick run command** | `npx vitest run src/components/wizard/BackendSelectionStep.test.tsx src/components/wizard/ReviewStep.test.tsx src/schemas/registry.test.ts` | | **Full suite command** | `npx vitest run` | | **Estimated runtime** | ~4 seconds | --- ## Sampling Rate - **After every task commit:** Run `npx vitest run` (full suite — ~3.4s, fast enough for every commit) - **After every plan wave:** Run `npx vitest run` + `npx tsc --noEmit` - **Before `/gsd:verify-work`:** Full suite must be green + zero TypeScript errors - **Max feedback latency:** ~4 seconds --- ## Per-Task Verification Map | Task ID | Plan | Wave | Requirement | Test Type | Automated Command | File Exists | Status | |---------|------|------|-------------|-----------|-------------------|-------------|--------| | 5-W0-01 | W0 | 0 | TECH-01 | unit | `npx vitest run src/components/wizard/ReviewStep.test.tsx` | ❌ W0 | ⬜ pending | | 5-W0-02 | W0 | 0 | TECH-02 | unit | `npx vitest run src/components/wizard/ReviewStep.test.tsx` | ❌ W0 | ⬜ pending | | 5-W0-03 | W0 | 0 | TECH-03 | unit | `npx vitest run src/schemas/registry.test.ts` | ❌ W0 | ⬜ pending | | 5-01-01 | 01 | 1 | TECH-01 | unit | `npx vitest run src/components/wizard/ReviewStep.test.tsx` | ❌ W0 | ⬜ pending | | 5-01-02 | 01 | 1 | TECH-02 | unit | `npx vitest run src/components/wizard/ReviewStep.test.tsx` | ❌ W0 | ⬜ pending | | 5-02-01 | 02 | 1 | TECH-03 | unit | `npx vitest run src/components/wizard/BackendSelectionStep.test.tsx src/schemas/registry.test.ts` | ✅ | ⬜ pending | | 5-03-01 | 03 | 1 | TECH-04 | type-check | `npx tsc --noEmit` | ✅ | ⬜ pending | | 5-04-01 | 04 | 1 | TECH-05 | unit | `npx vitest run src/components/wizard/BackendSelectionStep.test.tsx 2>&1 \| grep -c "act("` | ✅ | ⬜ pending | *Status: ⬜ pending · ✅ green · ❌ red · ⚠️ flaky* --- ## Wave 0 Requirements - [ ] `src/components/wizard/ReviewStep.test.tsx` — add cases for TECH-01: intune-only, rmm-only, neither (dispatch SET_DEPLOYMENT in test setup) - [ ] `src/components/wizard/ReviewStep.test.tsx` — add case for TECH-02: Back button renders and dispatches SET_STEP(2) - [ ] `src/schemas/registry.test.ts` — update field access to `.fields` after TECH-03 shape change --- ## Manual-Only Verifications | Behavior | Requirement | Why Manual | Test Instructions | |----------|-------------|------------|-------------------| | Back button returns to DeploymentStep without losing form data | TECH-02 | Form state persistence across navigation is hard to assert purely in unit tests | 1. Fill in DeploymentStep fields, 2. Advance to ReviewStep, 3. Click Back, 4. Verify DeploymentStep values are intact | --- ## Validation Sign-Off - [ ] All tasks have `` verify or Wave 0 dependencies - [ ] Sampling continuity: no 3 consecutive tasks without automated verify - [ ] Wave 0 covers all MISSING references - [ ] No watch-mode flags - [ ] Feedback latency < 4s - [ ] `nyquist_compliant: true` set in frontmatter **Approval:** pending