Every test module that needs Postgres repeats the same boilerplate: PgPool::connect, create_scratch_db, make_community, insert_user, cleanup. There is no shared test utility module. A #[cfg(test)] test-utils submodule with common helpers would reduce duplication and make writing new integration tests easier. Priority: Low — developer productivity improvement.
🤖 AI review update (2026-08-23)
Clarify who must consume the helpers. A plain cfg(test) module works only inside buzz-db; cross-crate and integration tests need tests/common, a dev-only support crate, or a feature-gated support module. Prefer sqlx::test where it fits, unique per-test databases/schemas, deterministic seed builders, and cleanup guards safe under parallel execution.
Every test module that needs Postgres repeats the same boilerplate:
PgPool::connect,create_scratch_db,make_community,insert_user, cleanup. There is no shared test utility module. A#[cfg(test)]test-utils submodule with common helpers would reduce duplication and make writing new integration tests easier. Priority: Low — developer productivity improvement.🤖 AI review update (2026-08-23)
Clarify who must consume the helpers. A plain cfg(test) module works only inside buzz-db; cross-crate and integration tests need tests/common, a dev-only support crate, or a feature-gated support module. Prefer sqlx::test where it fits, unique per-test databases/schemas, deterministic seed builders, and cleanup guards safe under parallel execution.