---
phase: 8
slug: discord-enrichment-and-external-jumps
status: draft
nyquist_compliant: false
wave_0_complete: false
created: 2026-03-12
---

# Phase 8 — Validation Strategy

> Per-phase validation contract for feedback sampling during execution.

---

## Test Infrastructure

| Property | Value |
|----------|-------|
| **Framework** | Rust built-in (`cargo test`) |
| **Config file** | none — standard Cargo test discovery |
| **Quick run command** | `cargo test -p app 2>&1 \| tail -20` |
| **Full suite command** | `cargo test --workspace 2>&1 \| tail -40` |
| **Estimated runtime** | ~15 seconds |

---

## Sampling Rate

- **After every task commit:** Run `cargo test -p app 2>&1 | tail -20`
- **After every plan wave:** Run `cargo test --workspace 2>&1 | tail -40`
- **Before `/gsd:verify-work`:** Full suite must be green
- **Max feedback latency:** 15 seconds

---

## Per-Task Verification Map

| Task ID | Plan | Wave | Requirement | Test Type | Automated Command | File Exists | Status |
|---------|------|------|-------------|-----------|-------------------|-------------|--------|
| 08-01-01 | 01 | 1 | CARD-01 | unit | `cargo test -p app discord_username` | ❌ W0 | ⬜ pending |
| 08-01-02 | 01 | 1 | CARD-02 | unit | `cargo test -p app avatar_initial` | ❌ W0 | ⬜ pending |
| 08-01-03 | 01 | 1 | DSC-03 | unit | `cargo test -p app contact_secondary` | ❌ W0 | ⬜ pending |
| 08-01-04 | 01 | 1 | DSC-04 | unit | `cargo test -p app open_discord_dm` | ❌ W0 | ⬜ pending |
| 08-02-01 | 02 | 1 | CARD-08 | unit | `cargo test -p app shopify_customer_url` | ❌ W0 | ⬜ pending |
| 08-02-02 | 02 | 1 | CARD-09 | unit | `cargo test -p app shopify_order_url` | ❌ W0 | ⬜ pending |
| 08-03-01 | 03 | 2 | CARD-08, CARD-09, DSC-04 | manual | Visual + functional check | N/A | ⬜ pending |

*Status: ⬜ pending · ✅ green · ❌ red · ⚠️ flaky*

---

## Wave 0 Requirements

- [ ] `crates/app/tests/discord_enrichment_tests.rs` — stubs for CARD-01, CARD-02, DSC-03, DSC-04
- [ ] `crates/app/tests/shopify_url_tests.rs` — stubs for CARD-08, CARD-09
- [ ] `crates/app/src/dashboard/external.rs` — new module for URL open + clipboard; must exist before tests can import it

---

## Manual-Only Verifications

| Behavior | Requirement | Why Manual | Test Instructions |
|----------|-------------|------------|-------------------|
| Discord DM opens in Discord app or browser | DSC-04 | OS-level protocol handler invocation | Click Discord DM button on a card with discord_user_id; verify Discord opens to user profile |
| Shopify customer/order links open in browser | CARD-08, CARD-09 | OS-level browser launch | Click Shopify customer/order links; verify correct admin URL opens |
| External jumps do not block UI thread | All | Requires runtime observation | Trigger external link while scrolling; UI remains responsive |

---

## 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 < 15s
- [ ] `nyquist_compliant: true` set in frontmatter

**Approval:** pending
