docs(phase-1): add validation strategy

This commit is contained in:
2026-03-25 11:23:37 +01:00
parent 55f74b66cb
commit dc5716db25
@@ -0,0 +1,80 @@
---
phase: 1
slug: capture-and-classification
status: draft
nyquist_compliant: false
wave_0_complete: false
created: 2026-03-25
---
# Phase 1 — Validation Strategy
> Per-phase validation contract for feedback sampling during execution.
---
## Test Infrastructure
| Property | Value |
|----------|-------|
| **Framework** | go test |
| **Config file** | none — Wave 0 installs |
| **Quick run command** | `go test ./...` |
| **Full suite command** | `go test -v -race ./...` |
| **Estimated runtime** | ~5 seconds |
---
## Sampling Rate
- **After every task commit:** Run `go test ./...`
- **After every plan wave:** Run `go test -v -race ./...`
- **Before `/gsd:verify-work`:** Full suite must be green
- **Max feedback latency:** 5 seconds
---
## Per-Task Verification Map
| Task ID | Plan | Wave | Requirement | Test Type | Automated Command | File Exists | Status |
|---------|------|------|-------------|-----------|-------------------|-------------|--------|
| 01-01-01 | 01 | 1 | CAPT-01 | integration | `go test -run TestInterfaceFlag ./cmd/...` | ❌ W0 | ⬜ pending |
| 01-01-02 | 01 | 1 | CAPT-02 | unit | `go test -run TestListInterfaces ./cmd/...` | ❌ W0 | ⬜ pending |
| 01-01-03 | 01 | 1 | CAPT-04 | unit | `go test -run TestPrivilegeError ./internal/capture/...` | ❌ W0 | ⬜ pending |
| 01-02-01 | 02 | 1 | CLAS-01 | unit | `go test -run TestClassify ./internal/classify/...` | ❌ W0 | ⬜ pending |
| 01-02-02 | 02 | 1 | CLAS-03 | unit | `go test -run TestExitSummary ./internal/stats/...` | ❌ W0 | ⬜ pending |
| 01-02-03 | 02 | 1 | CLAS-04 | unit | `go test -run TestVerboseLog ./internal/stats/...` | ❌ W0 | ⬜ pending |
*Status: ⬜ pending · ✅ green · ❌ red · ⚠️ flaky*
---
## Wave 0 Requirements
- [ ] `go.mod` — initialize Go module
- [ ] Go 1.24+ installed on machine
- [ ] Test file stubs for each requirement
*If none: "Existing infrastructure covers all phase requirements."*
---
## Manual-Only Verifications
| Behavior | Requirement | Why Manual | Test Instructions |
|----------|-------------|------------|-------------------|
| Live packet capture on real interface | CAPT-01 | Requires root/CAP_NET_RAW and active network | Run `sudo ./netsynth -i <iface>`, verify packets appear on stderr |
| Platform-specific privilege message | CAPT-04 | OS-specific behavior, hard to unit test | Run without sudo on Linux and macOS, verify correct hint text |
---
## 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 < 5s
- [ ] `nyquist_compliant: true` set in frontmatter
**Approval:** pending