The six gorm.Open calls in the internal/delivery tests (archive_sweeper_test.go three times, engine_test.go, engine_integration_test.go, target_database_test.go) passed a bare &gorm.Config{}, which installs GORM's default logger. Each now passes gormlog.New over an slog logger with slog.DiscardHandler, so no gorm.Open in the tree is left on the bare form for someone to copy into production code. No existing test helper discards: archiveTestLogger writes to standard error at debug level, so wrapping it would have printed every test statement.
README.md and the ParamsFilter comment in internal/gormlog/gormlog.go said (*gorm.DB).Scan had one caller, internal/database/database_test.go:91. That is stale: internal/database/event_tier_indexes_test.go calls it too, with bound values. Both now say only tests call it and what a test binds is fixture data, the wording the guard test already uses, so the sentence does not go stale again when a test adds a call.
A side effect worth knowing: these test databases no longer write through gormlogger.Default, so the two tests that swap that process-global logger to catch a bare config in production no longer share it with them.
Model: opus-5-5
The six `gorm.Open` calls in the `internal/delivery` tests (`archive_sweeper_test.go` three times, `engine_test.go`, `engine_integration_test.go`, `target_database_test.go`) passed a bare `&gorm.Config{}`, which installs GORM's default logger. Each now passes `gormlog.New` over an `slog` logger with `slog.DiscardHandler`, so no `gorm.Open` in the tree is left on the bare form for someone to copy into production code. No existing test helper discards: `archiveTestLogger` writes to standard error at debug level, so wrapping it would have printed every test statement.
`README.md` and the `ParamsFilter` comment in `internal/gormlog/gormlog.go` said `(*gorm.DB).Scan` had one caller, `internal/database/database_test.go:91`. That is stale: `internal/database/event_tier_indexes_test.go` calls it too, with bound values. Both now say only tests call it and what a test binds is fixture data, the wording the guard test already uses, so the sentence does not go stale again when a test adds a call.
A side effect worth knowing: these test databases no longer write through `gormlogger.Default`, so the two tests that swap that process-global logger to catch a bare config in production no longer share it with them.
Model: opus-5-5
The six gorm.Open calls in the internal/delivery tests passed a bare
gorm.Config, which installs GORM's default logger; they now pass
gormlog.New over a logger that discards, as every production call does,
so the unfiltered form is no longer in the tree to be copied.
The README and the ParamsFilter comment said (*gorm.DB).Scan had one
test-only caller; there are more. Both now say only tests call it, with
fixture data.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
The six
gorm.Opencalls in theinternal/deliverytests (archive_sweeper_test.gothree times,engine_test.go,engine_integration_test.go,target_database_test.go) passed a bare&gorm.Config{}, which installs GORM's default logger. Each now passesgormlog.Newover ansloglogger withslog.DiscardHandler, so nogorm.Openin the tree is left on the bare form for someone to copy into production code. No existing test helper discards:archiveTestLoggerwrites to standard error at debug level, so wrapping it would have printed every test statement.README.mdand theParamsFiltercomment ininternal/gormlog/gormlog.gosaid(*gorm.DB).Scanhad one caller,internal/database/database_test.go:91. That is stale:internal/database/event_tier_indexes_test.gocalls it too, with bound values. Both now say only tests call it and what a test binds is fixture data, the wording the guard test already uses, so the sentence does not go stale again when a test adds a call.A side effect worth knowing: these test databases no longer write through
gormlogger.Default, so the two tests that swap that process-global logger to catch a bare config in production no longer share it with them.Model: opus-5-5
Review passed.
Model: opus-5-5