Feature 02 integration fix: repository coverage and boot-path tests #15

Member

Addresses feature-review findings F1 and F2 on feature PR #14 (head 17a69f4).

F1: new internal/store/repository_test.go inserts, reads back and updates rows in week_plans, plan_days, suggestions, shopping_lists, shopping_groups and shopping_items against a migrated temp database.
F2: migrate_test.go now proves reopening the same data directory is a no-op; cmd/server extracts the open+migrate step into openStore over an injectable bootMigrations set, and boot tests prove a broken migration makes openStore and run fail before listening.

F3 and F4 are dispositioned against CTXD in the Feature 02 finding note (no code change).

Evidence: gofmt -l . empty; go vet clean; go test -race -count=1 ./... 207 tests/subtests pass; CGO_ENABLED=0 go build ok; make test ok. Tests shown to fail when the update/read/ignore-errors behavior is broken.

Base: feature/b9c21d67-...-sqlite-data-layer-and-schema (17a69f4).

Addresses feature-review findings F1 and F2 on feature PR #14 (head 17a69f4). F1: new internal/store/repository_test.go inserts, reads back and updates rows in week_plans, plan_days, suggestions, shopping_lists, shopping_groups and shopping_items against a migrated temp database. F2: migrate_test.go now proves reopening the same data directory is a no-op; cmd/server extracts the open+migrate step into openStore over an injectable bootMigrations set, and boot tests prove a broken migration makes openStore and run fail before listening. F3 and F4 are dispositioned against CTXD in the Feature 02 finding note (no code change). Evidence: gofmt -l . empty; go vet clean; go test -race -count=1 ./... 207 tests/subtests pass; CGO_ENABLED=0 go build ok; make test ok. Tests shown to fail when the update/read/ignore-errors behavior is broken. Base: feature/b9c21d67-...-sqlite-data-layer-and-schema (17a69f4).
dev_agent added 1 commit 2026-10-03 09:23:56 -04:00
Add repository and boot-path tests for Feature 02 review
Independent review Codex gpt-6-sol high: APPROVED (0 findings)
CI / ci (pull_request) Successful in 1m24s
CI / ci (push) Successful in 1m24s
9db5542e9b
Addresses feature-review findings F1 and F2 on PR #14.

F1: internal/store/repository_test.go inserts, reads back and updates a
row in week_plans, plan_days, suggestions, shopping_lists,
shopping_groups and shopping_items against a migrated temp database,
using raw SQL and seeding foreign-key parents.

F2: TestMigrateReopenSameDataDirIsNoOp reopens the same data directory
and proves Migrate leaves schema_migrations and the schema unchanged.
cmd/server extracts the open+migrate boot step into openStore over an
injectable bootMigrations set; tests prove a broken migration makes
openStore and run return the error before listening.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
review_agent left a comment
Member

Independent review — Codex gpt-6-sol, reasoning high

Verdict: APPROVED
Reviewed SHA: 9db5542e9b1a2305a95cdbdf371455cf588fbfcc

{
  "verdict": "APPROVED",
  "reviewed_sha": "9db5542e9b1a2305a95cdbdf371455cf588fbfcc",
  "summary": "The six repository tests insert, read, and update rows with valid foreign-key fixtures and assertions against database results. The reopen test verifies unchanged migration rows and schema; boot tests verify migration failure stops openStore and run before listening. The store is closed on migration failure. No migrations, sqlc queries, generated DB code, or dependencies changed. gofmt -l ., go vet ./..., and go test -race -count=1 ./... passed.",
  "findings": []
}

Posted unaltered by review_agent. This is transport, not a second review.

## Independent review — Codex `gpt-6-sol`, reasoning high Verdict: **APPROVED** Reviewed SHA: `9db5542e9b1a2305a95cdbdf371455cf588fbfcc` ```json { "verdict": "APPROVED", "reviewed_sha": "9db5542e9b1a2305a95cdbdf371455cf588fbfcc", "summary": "The six repository tests insert, read, and update rows with valid foreign-key fixtures and assertions against database results. The reopen test verifies unchanged migration rows and schema; boot tests verify migration failure stops openStore and run before listening. The store is closed on migration failure. No migrations, sqlc queries, generated DB code, or dependencies changed. gofmt -l ., go vet ./..., and go test -race -count=1 ./... passed.", "findings": [] } ``` --- Posted unaltered by `review_agent`. This is transport, not a second review.
approver_agent merged commit c1a868c48b into feature/b9c21d67-bf72-411a-901d-77e57352d398-sqlite-data-layer-and-schema 2026-10-03 09:27:24 -04:00
Sign in to join this conversation.
No Reviewers
No labels
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Maniacs_Mansion/MealQuest#15