Split out of #232, which listed it as "also worth folding in" after its definition of done.
Six test-only gorm.Open calls in internal/delivery (archive_sweeper_test.go three times, engine_test.go, engine_integration_test.go, target_database_test.go) still pass a bare &gorm.Config{} instead of a logger built by gormlog.New. No secrets are involved, since they open fixture data only, and every production gorm.Open goes through gormlog.New. But the unfiltered idiom stays in the tree to be copied into production code.
Definition of done
No gorm.Open in the tree uses a bare &gorm.Config{}: the test sites use gormlog.New over a logger that discards, or a test helper that already does.
Nothing else changes.
Model: opus-5-5
Split out of https://git.eeqj.de/sneak/webhooker/issues/232, which listed it as "also worth folding in" after its definition of done.
Six test-only `gorm.Open` calls in `internal/delivery` (`archive_sweeper_test.go` three times, `engine_test.go`, `engine_integration_test.go`, `target_database_test.go`) still pass a bare `&gorm.Config{}` instead of a logger built by `gormlog.New`. No secrets are involved, since they open fixture data only, and every production `gorm.Open` goes through `gormlog.New`. But the unfiltered idiom stays in the tree to be copied into production code.
## Definition of done
- No `gorm.Open` in the tree uses a bare `&gorm.Config{}`: the test sites use `gormlog.New` over a logger that discards, or a test helper that already does.
- Nothing else changes.
Model: opus-5-5
Also in scope, found by the review of #456: the sentence saying the tree has one test-only (*gorm.DB).Scan caller is stale in README.md (around line 2611) and in the comment in internal/gormlog/gormlog.go (lines 114 to 116); correct both.
Model: opus-5-5
Also in scope, found by the review of https://git.eeqj.de/sneak/webhooker/pulls/456: the sentence saying the tree has one test-only `(*gorm.DB).Scan` caller is stale in `README.md` (around line 2611) and in the comment in `internal/gormlog/gormlog.go` (lines 114 to 116); correct both.
Model: opus-5-5
The six gorm.Open calls in the internal/delivery tests now pass gormlog.New over an slog logger that discards, so no gorm.Open in the tree uses a bare gorm.Config any more. The stale sentence about (*gorm.DB).Scan having one test-only caller is corrected in README.md and in the ParamsFilter comment in internal/gormlog/gormlog.go.
Judgement call: the corrected sentence says only tests call Scan and what a test binds is fixture data, rather than listing the callers by file and line, so it does not go stale again when a test adds one.
Judgement call: the test sites build the discarding logger inline; the package's existing test logger writes every statement to standard error at debug level, so it does not discard.
Model: opus-5-5
Done in https://git.eeqj.de/sneak/webhooker/pulls/466.
The six `gorm.Open` calls in the `internal/delivery` tests now pass `gormlog.New` over an `slog` logger that discards, so no `gorm.Open` in the tree uses a bare `gorm.Config` any more. The stale sentence about `(*gorm.DB).Scan` having one test-only caller is corrected in `README.md` and in the `ParamsFilter` comment in `internal/gormlog/gormlog.go`.
- Judgement call: the corrected sentence says only tests call `Scan` and what a test binds is fixture data, rather than listing the callers by file and line, so it does not go stale again when a test adds one.
- Judgement call: the test sites build the discarding logger inline; the package's existing test logger writes every statement to standard error at debug level, so it does not discard.
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.
Split out of #232, which listed it as "also worth folding in" after its definition of done.
Six test-only
gorm.Opencalls ininternal/delivery(archive_sweeper_test.gothree times,engine_test.go,engine_integration_test.go,target_database_test.go) still pass a bare&gorm.Config{}instead of a logger built bygormlog.New. No secrets are involved, since they open fixture data only, and every productiongorm.Opengoes throughgormlog.New. But the unfiltered idiom stays in the tree to be copied into production code.Definition of done
gorm.Openin the tree uses a bare&gorm.Config{}: the test sites usegormlog.Newover a logger that discards, or a test helper that already does.Model: opus-5-5
Also in scope, found by the review of #456: the sentence saying the tree has one test-only
(*gorm.DB).Scancaller is stale inREADME.md(around line 2611) and in the comment ininternal/gormlog/gormlog.go(lines 114 to 116); correct both.Model: opus-5-5
Done in #466.
The six
gorm.Opencalls in theinternal/deliverytests now passgormlog.Newover ansloglogger that discards, so nogorm.Openin the tree uses a baregorm.Configany more. The stale sentence about(*gorm.DB).Scanhaving one test-only caller is corrected inREADME.mdand in theParamsFiltercomment ininternal/gormlog/gormlog.go.Scanand what a test binds is fixture data, rather than listing the callers by file and line, so it does not go stale again when a test adds one.Model: opus-5-5