1.5 KiB
1.5 KiB
id, title, status, wave, depends_on, plan, spec
| id | title | status | wave | depends_on | plan | spec |
|---|---|---|---|---|---|---|
| 01-persist-default-saved-queries | Persist default saved queries | done | 1 | plan.md | ../../specs/ui/github-saved-query-defaults.md |
Task 01: Persist Default Saved Queries
Acceptance
- Legacy arrays normalize missing markers to
falseand duplicate defaults to the first valid entry per kind. - Setting, replacing, and clearing one kind's default preserves the other kind.
- Workspace and user-setting writes publish new markers only after success; failed workspace writes retain prior state.
TDD sequence
- Add pure-model and hook regressions and confirm expected RED failures.
- Add the normalized model and acknowledged persistence mutation.
- Rerun focused suites and refactor while green.
Files
apps/web/components/github/my-github/saved-preset-model.tsapps/web/components/github/my-github/saved-preset-model.test.tsapps/web/components/github/my-github/use-saved-presets.tsapps/web/components/github/my-github/use-saved-presets.test.ts
Verification
cd apps && pnpm --filter @kandev/web exec vitest run components/github/my-github/saved-preset-model.test.ts components/github/my-github/use-saved-presets.test.ts
Result
- RED: 2 normalization assertions failed because legacy and duplicate markers were not normalized; 6 model-export assertions and 4 persistence assertions then failed before their implementations existed.
- GREEN: focused command passed 21 tests across 2 files.