|
2 | 2 |
|
3 | 3 | This is the active testing guide for Taskdeck. |
4 | 4 |
|
5 | | -Last Updated: 2026-04-25 |
| 5 | +Last Updated: 2026-04-26 |
6 | 6 | Companion Active Docs: |
7 | 7 | - `docs/STATUS.md` |
8 | 8 | - `docs/IMPLEMENTATION_MASTERPLAN.md` |
9 | 9 | - `docs/TESTING_GUIDE.md` |
10 | 10 | - `docs/MANUAL_TEST_CHECKLIST.md` |
11 | 11 | - `docs/GOLDEN_PRINCIPLES.md` |
12 | 12 |
|
13 | | -## Current Verified Totals (2026-04-25) |
| 13 | +## Current Verified Totals (2026-04-26) |
14 | 14 |
|
15 | | -- Backend: **5,060 passing** (0 failing, 2 skipped; 5,062 total) -- verified 2026-04-25 via `dotnet test backend/Taskdeck.sln -c Release -m:1` on `main` |
16 | | - - Domain: 962 passed |
17 | | - - Application: 2,367 passed |
| 15 | +- Backend: **~5,520 passing** (estimated; 5,060 at last recertification + ~460 new tests from Paper backend gap wave PRs `#1031`–`#1040`) |
| 16 | + - Domain: ~1,120 passed (962 + ~158 new domain tests) |
| 17 | + - Application: ~2,670 passed (2,367 + ~302 new application tests) |
18 | 18 | - API integration: 1,621 passed (0 failed, 2 skipped; 1,623 total) |
19 | 19 | - CLI contract: 82 passed |
20 | 20 | - Architecture boundaries: 8 passed |
21 | 21 | - Integration (Testcontainers): 20 passed |
22 | 22 | - Frontend unit: **2,805 passing** across 214+ test files -- verified 2026-04-25 via `npx vitest --run --reporter=verbose` on `main` |
23 | 23 | - Frontend E2E (smoke + automation/ops + capture loop + starter-pack fixtures + concurrency harness + error recovery/multi-board/edge journeys + cross-browser matrix + onboarding/review/capture/keyboard/dark-mode + validation slices C/D/E + integrated verification): default required lane passing; +20 new scenarios in PRs `#821`–`#826`; +61 new validation/verification scenarios in PRs `#837`–`#840` + `#838` |
24 | | -- Combined automated total: **7,865+ passing** (backend 5,060 + frontend unit 2,805 + E2E) |
| 24 | +- Combined automated total: **~8,325+ passing** (backend ~5,520 + frontend unit 2,805 + E2E) |
25 | 25 |
|
26 | 26 | Verification note: |
27 | | -- backend total of 5,060 passing (0 failing, 2 skipped; 5,062 total) recertified 2026-04-25 via `dotnet test backend/Taskdeck.sln -c Release -m:1` on `main` (PR `#987`) |
28 | | -- frontend total of 2,805 passing across 214+ test files recertified 2026-04-25 via `npx vitest --run --reporter=verbose` on `main` (PR `#987`) |
29 | | -- 5 previously-failing Api.Tests (3 CorsApiTests, 1 McpTelemetryMiddlewareTests, 1 SecurityHeadersApiTests) now pass |
30 | | -- prior recertification: backend 4,979 (2026-04-23), frontend 2,607 (2026-04-23) at commit `97d4856c` |
31 | | -- growth since last recertification: backend +81 tests, frontend +198 tests |
| 27 | +- backend total of ~5,520 is estimated pending recertification after Paper backend gap PRs merge; ~460 new tests verified individually per PR via CI |
| 28 | +- Paper backend gap wave (2026-04-26, PRs `#1031`–`#1040`): ~460 new tests across 10 issues; each PR CI-verified independently |
| 29 | +- prior recertification: backend 5,060 (2026-04-25), frontend 2,805 (2026-04-25) at PR `#987` |
| 30 | +- growth since last recertification: backend +~460 tests (Paper backend gaps), frontend unchanged |
32 | 31 |
|
33 | 32 | ## Roadmap v4 Verification Spine (Seeded 2026-04-25) |
34 | 33 |
|
@@ -57,6 +56,131 @@ Pop-Location |
57 | 56 | if ($code -ne 0) { exit $code } |
58 | 57 | ``` |
59 | 58 |
|
| 59 | +## Paper Backend Gap Testing (2026-04-26, PRs `#1031`–`#1040`) |
| 60 | + |
| 61 | +The Paper backend gap wave (PRs `#1031`–`#1040`) added ~460 new backend tests across 10 issues. Each PR received two rounds of adversarial review; the second round found and fixed issues including a P1 false-warning bug, a 100k entity memory risk, a board-scoping error, missing FK enforcement, and CancellationToken threading gaps. |
| 62 | + |
| 63 | +### Cadence Aggregation Tests (`#1015`/`#1031`) |
| 64 | + |
| 65 | +`backend/tests/Taskdeck.Domain.Tests/Entities/CadenceSnapshotTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/CadenceServiceTests.cs` — **26 tests** covering: |
| 66 | +- CadenceBucket hour validation (0-23), event count non-negative, equality semantics |
| 67 | +- CadenceSnapshot: 24-bucket invariant, null guard, cached `Empty()` singleton, first/peak/last action computation |
| 68 | +- CadenceService: empty day, single event, full day aggregation, peak hour ties, midnight boundary, date normalization |
| 69 | + |
| 70 | +Run: |
| 71 | +```bash |
| 72 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~Cadence" |
| 73 | +``` |
| 74 | + |
| 75 | +### Streak Query Tests (`#1016`/`#1032`) |
| 76 | + |
| 77 | +`backend/tests/Taskdeck.Domain.Tests/Entities/StreakDayTests.cs`, `StreakResultTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/StreakServiceTests.cs` — **61 tests** covering: |
| 78 | +- StreakDay: intensity bucket validation (0-4), DateOnly handling, sealed flag |
| 79 | +- StreakResult: current/longest streak invariant (current cannot exceed longest), empty days |
| 80 | +- StreakService: empty history, single day, continuous streak, gap in streak, gap at end, intensity quartile bucketing, day count boundaries (1, 90, 365), server-side `CountByDateAsync` aggregate query |
| 81 | + |
| 82 | +Run: |
| 83 | +```bash |
| 84 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~Streak" |
| 85 | +``` |
| 86 | + |
| 87 | +### Seal Day Tests (`#1017`/`#1037`) |
| 88 | + |
| 89 | +`backend/tests/Taskdeck.Domain.Tests/Entities/DailySnapshotTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/DailySealServiceTests.cs` — **28 tests** covering: |
| 90 | +- DailySnapshot: construction, seal idempotency (second seal is no-op preserving original timestamp), future date rejection, IsSealed property, empty userId rejection |
| 91 | +- DailySealService: seal new day, seal existing unsealed, seal already-sealed (idempotent), validation errors, status checks for missing/sealed/unsealed snapshots, CancellationToken propagation |
| 92 | +- UnitOfWork: DailySnapshot unique constraint violation recovery (concurrent seal race condition) |
| 93 | + |
| 94 | +Run: |
| 95 | +```bash |
| 96 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~Seal or FullyQualifiedName~DailySnapshot" |
| 97 | +``` |
| 98 | + |
| 99 | +### Tomorrow Note Tests (`#1018`/`#1035`) |
| 100 | + |
| 101 | +`backend/tests/Taskdeck.Domain.Tests/Entities/TomorrowNoteTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/TomorrowNoteServiceTests.cs` — **25 tests** covering: |
| 102 | +- TomorrowNote: constructor validation, text max length (500 chars), date handling, UpdateText behavior and timestamp |
| 103 | +- TomorrowNoteService: get existing/missing note, save new/update existing (upsert), empty userId rejection, null text handling, max length boundary |
| 104 | +- UnitOfWork: TomorrowNote unique constraint violation recovery (concurrent upsert race condition) |
| 105 | + |
| 106 | +Run: |
| 107 | +```bash |
| 108 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~TomorrowNote" |
| 109 | +``` |
| 110 | + |
| 111 | +### Provenance Query Tests (`#1019`/`#1039`) |
| 112 | + |
| 113 | +`backend/tests/Taskdeck.Application.Tests/Services/ProvenanceQueryServiceTests.cs` — **41 tests** covering: |
| 114 | +- Icon map: 26-entry case-insensitive map with fallback default icon |
| 115 | +- Weight bucketing: extractive >= 0.7 confidence → "primary", < 0.7 → "contextual", inferred → "inferred" |
| 116 | +- Human-readable value strings with quote snippet truncation, `Math.Round` for confidence display |
| 117 | +- Empty provenance (returns empty list, not error), missing proposal, authorization |
| 118 | +- FK enforcement via `AddProposalProvenanceForeignKey` migration |
| 119 | + |
| 120 | +Run: |
| 121 | +```bash |
| 122 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~ProvenanceQuery" |
| 123 | +``` |
| 124 | + |
| 125 | +### Side-Effect Analysis Tests (`#1020`/`#1033`) |
| 126 | + |
| 127 | +`backend/tests/Taskdeck.Domain.Tests/Entities/SideEffectTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/SideEffectAnalyzerTests.cs` — **66 tests** covering: |
| 128 | +- SideEffectRow: value object creation, tone enum, equality/hash contract |
| 129 | +- Reversibility: default 6h window (21,600,000ms), summary/description |
| 130 | +- SideEffectAnalyzer: 7-category tone classification (Cards, Subtasks, Comments, Activity, Notifications, Webhooks, Calendar), target-type-aware card mutation detection, column mutation inclusion, webhook conditional on operations existing, risk-based reversibility (Critical → 3h) |
| 131 | + |
| 132 | +Run: |
| 133 | +```bash |
| 134 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~SideEffect" |
| 135 | +``` |
| 136 | + |
| 137 | +### Confidence Breakdown Tests (`#1021`/`#1036`) |
| 138 | + |
| 139 | +`backend/tests/Taskdeck.Domain.Tests/Confidence/ConfidenceComponentTests.cs`, `ConfidenceBreakdownTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/Confidence/ConfidenceBreakdownServiceTests.cs` — **63 tests** covering: |
| 140 | +- ConfidenceComponent: value range [0..1], NaN/Infinity rejection, key validation |
| 141 | +- ConfidenceBreakdown: overall/threshold range, MeetsThreshold computed property, defensive component list copy |
| 142 | +- ConfidenceBreakdownService: 4-component weighted computation (Pattern match, Reach, Reversibility, Recency), reach formula `2.0 / (2.0 + log2(n))`, risk-level reversibility scoring, recency from expiry window, threshold note generation, static weight map |
| 143 | + |
| 144 | +Run: |
| 145 | +```bash |
| 146 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~ConfidenceBreakdown" |
| 147 | +``` |
| 148 | + |
| 149 | +### Conflict Detection Tests (`#1022`/`#1040`) |
| 150 | + |
| 151 | +`backend/tests/Taskdeck.Domain.Tests/Entities/ConflictRowTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/ProposalConflictDetectorTests.cs` — **46 tests** covering: |
| 152 | +- ConflictRow: tone enum, value object creation, equality |
| 153 | +- ProposalConflictDetector: 7 detection rules — stale data (excludes create-card ops), missing target card, WIP limit, duplicate pending proposals (all pending, not just latest), high/critical risk, outbound webhooks, active comments, multi-op on same card, positive signals (column capacity, fresh data) |
| 154 | +- Entity caching (each card/column fetched at most once), safe JSON parsing with ValueKind checks, tone-sorted output (Warn → Info → Ok) |
| 155 | + |
| 156 | +Run: |
| 157 | +```bash |
| 158 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~ConflictRow or FullyQualifiedName~ConflictDetector" |
| 159 | +``` |
| 160 | + |
| 161 | +### Card History Tests (`#1023`/`#1034`) |
| 162 | + |
| 163 | +`backend/tests/Taskdeck.Domain.Tests/Entities/CardHistoryRowTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/CardHistoryServiceTests.cs` — **42 tests** covering: |
| 164 | +- CardHistoryRow: serial formatting, status enum, validation, equality |
| 165 | +- CardHistoryService: single/multi-card history, serial numbering, age formatting (same day, yesterday, this week, older) with `InvariantCulture`, status classification (pending/applied/past), proposal deduplication via `HashSet<Guid>`, bounded output (200/card, 500 total), proper JSON property parsing for update events |
| 166 | + |
| 167 | +Run: |
| 168 | +```bash |
| 169 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~CardHistory" |
| 170 | +``` |
| 171 | + |
| 172 | +### Similar Past Decisions Tests (`#1024`/`#1038`) |
| 173 | + |
| 174 | +`backend/tests/Taskdeck.Domain.Tests/SimilarPast/SimilarPastDecisionTests.cs`, `SimilarPastResultTests.cs`, `backend/tests/Taskdeck.Application.Tests/Services/SimilarDecisionServiceTests.cs` — **50 tests** covering: |
| 175 | +- SimilarPastDecision: value object validation, title truncation (200 chars), verdict enum |
| 176 | +- SimilarPastResult: apply rate computation, division-by-zero safety, negative input rejection |
| 177 | +- SimilarDecisionService: board-scoped action-class matching (review fixed userId filter), user-scoped fallback, top-3 limiting with full-population apply rate, self-exclusion, serial/date formatting (ISO week with 2-digit year), 200-proposal lookback limit, SARGable `OrderByDescending(DecidedAt)` ordering |
| 178 | + |
| 179 | +Run: |
| 180 | +```bash |
| 181 | +dotnet test backend/Taskdeck.sln -c Release --filter "FullyQualifiedName~SimilarPast or FullyQualifiedName~SimilarDecision" |
| 182 | +``` |
| 183 | + |
60 | 184 | ## Roadmap v4 Second-Wave Testing (2026-04-25, PRs `#989`–`#994`) |
61 | 185 |
|
62 | 186 | The RFAI-02 through RFAI-08 foundational slice wave (PRs `#989`–`#994`) added ~631 new backend tests across 6 PRs. Each PR received adversarial review with review-added tests fixing bot findings from Gemini and Codex connector reviews. |
|
0 commit comments