fix(tests): make just test pass again #94

Merged
nrupard merged 1 commit from fix/just-test-stale-migrations into main 2026-05-14 18:14:10 +02:00
Owner

just test failed on three fronts. First, linking the ~50 statically-linked test binaries 8-way parallel exhausted memory on a swapless host and the OOM killer terminated ld (SIGTERM). Cap test linking at --jobs 2 and trim dev/test debug info to line tables so each link has a smaller footprint.

Second, email_digest_dispatch constructed AppState without the bg field added by the background-writer work, so the suite no longer compiled.

Third, most test files hand-listed include_str! migrations and had silently gone stale: new chat/auth migrations (notably messages.quote_id) were never applied, so 18 suites failed at runtime with "table messages has no column named quote_id". Replace the hand-rolled lists with a shared tests/common helper that runs the full embedded migration set via sqlx::migrate!, so new migrations are picked up automatically. Also refresh the stale invite_then_accept_creates_membership enclave test to match the current post_invite API (user_id form field, HTML 200 response instead of a redirect).

Co-Authored-By: Claude Opus 4.7 noreply@anthropic.com

`just test` failed on three fronts. First, linking the ~50 statically-linked test binaries 8-way parallel exhausted memory on a swapless host and the OOM killer terminated `ld` (SIGTERM). Cap test linking at `--jobs 2` and trim dev/test debug info to line tables so each link has a smaller footprint. Second, `email_digest_dispatch` constructed `AppState` without the `bg` field added by the background-writer work, so the suite no longer compiled. Third, most test files hand-listed `include_str!` migrations and had silently gone stale: new chat/auth migrations (notably `messages.quote_id`) were never applied, so 18 suites failed at runtime with "table messages has no column named quote_id". Replace the hand-rolled lists with a shared `tests/common` helper that runs the full embedded migration set via `sqlx::migrate!`, so new migrations are picked up automatically. Also refresh the stale `invite_then_accept_creates_membership` enclave test to match the current `post_invite` API (`user_id` form field, HTML 200 response instead of a redirect). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
fix(tests): make just test pass again
Some checks failed
Check / clippy + fmt + tests (pull_request) Failing after 24s
2e24b00040
`just test` failed on three fronts. First, linking the ~50 statically-linked test binaries 8-way parallel exhausted memory on a swapless host and the OOM killer terminated `ld` (SIGTERM). Cap test linking at `--jobs 2` and trim dev/test debug info to line tables so each link has a smaller footprint.

Second, `email_digest_dispatch` constructed `AppState` without the `bg` field added by the background-writer work, so the suite no longer compiled.

Third, most test files hand-listed `include_str!` migrations and had silently gone stale: new chat/auth migrations (notably `messages.quote_id`) were never applied, so 18 suites failed at runtime with "table messages has no column named quote_id". Replace the hand-rolled lists with a shared `tests/common` helper that runs the full embedded migration set via `sqlx::migrate!`, so new migrations are picked up automatically. Also refresh the stale `invite_then_accept_creates_membership` enclave test to match the current `post_invite` API (`user_id` form field, HTML 200 response instead of a redirect).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
nrupard deleted branch fix/just-test-stale-migrations 2026-05-14 18:14:10 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
psa-systems/lets-chat!94
No description provided.