Files
familysync/.planning/phases/04-shared-lists-live-sync/04-VALIDATION.md
T

3.9 KiB

phase, slug, status, nyquist_compliant, wave_0_complete, created
phase slug status nyquist_compliant wave_0_complete created
4 shared-lists-live-sync draft false false 2026-06-09

Phase 4 — Validation Strategy

Per-phase validation contract for feedback sampling during execution. Source: 04-RESEARCH.md §"Validation Architecture".


Test Infrastructure

Property Value
Framework Vitest ^4.1.8 (existing)
Config file apps/api/vitest.config.ts + apps/pwa/vitest.config.ts (existing)
Quick run command pnpm --filter @familysync/api test / pnpm --filter @familysync/pwa test
Full suite command pnpm test (root, all workspaces)
Estimated runtime ~TBD seconds (planner to confirm)

Sampling Rate

  • After every task commit: Run the relevant workspace quick command (pnpm --filter @familysync/api test or … pwa test)
  • After every plan wave: Run pnpm test
  • Before /gsd-verify-work: Full suite must be green
  • Max feedback latency: TBD seconds

Per-Task Verification Map

Planner fills this from the Phase Requirements → Test Map in 04-RESEARCH.md. Seed rows (from RESEARCH):

Task ID Plan Wave Requirement Threat Ref Secure Behavior Test Type Automated Command File Exists Status
4-XX-XX XX X LIST-01 Create list inserts row + list_shares for shared unit (API) pnpm --filter @familysync/api test W0 pending
4-XX-XX XX X LIST-01 GET /api/lists returns only accessible lists (owner + shares) unit (API) pnpm --filter @familysync/api test W0 pending
4-XX-XX XX X LIST-02 PATCH checked:true updates only checked (per-field) unit (API) pnpm --filter @familysync/api test W0 pending
4-XX-XX XX X LIST-03 PATCH new rank produces correct fractional order unit (API) pnpm --filter @familysync/api test W0 pending
4-XX-XX XX X LIST-04 T-4-xx Private-list events NOT emitted to non-owner subscriber unit (API) pnpm --filter @familysync/api test W0 pending
4-XX-XX XX X D-11 Bounded backoff hook exhausts after capped attempts unit (PWA) pnpm --filter @familysync/pwa test W0 pending
4-XX-XX XX X D-07 Optimistic update rolls back on mutation error unit (PWA) pnpm --filter @familysync/pwa test W0 pending

Status: pending · green · red · ⚠️ flaky


Wave 0 Requirements

  • apps/api/src/routes/lists.test.ts — LIST-01/02/03/04 API behavior
  • apps/api/src/lib/listEmitter.test.ts — scoped fan-out correctness (D-04)
  • apps/pwa/src/hooks/useListSSE.test.ts — D-11 bounded backoff with mock EventSource
  • apps/pwa/src/routes/ListDetail.test.tsx — optimistic update + rollback (D-07)

Manual-Only Verifications

Behavior Requirement Why Manual Test Instructions
Cross-device live co-edit (one member's change appears for the other within seconds) LIST-04 / success criterion 3 Two-client real-time behavior over the deployed tunnel; better observed in a browser Drive with playwright-cli (two contexts) where possible; iOS-Safari standalone behavior needs a device

Drag-and-drop reorder (LIST-03) and SSE live sync should be validated in-browser via playwright-cli per project convention.


Validation Sign-Off

  • All tasks have <automated> 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 target set
  • nyquist_compliant: true set in frontmatter

Approval: pending