ci(coverage): add postgres + redis + mongo service containers#46
Merged
Conversation
Coverage workflow tests were failing with connection-refused because the runner had no DB. Adds postgres:15, redis:7, mongo:6 service containers + TEST_*_URL env vars so coverage reflects real test execution rather than the no-DB slice. Per CLAUDE.md 95% coverage target. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
go test ./...against a runner with no DB / no Redis / no Mongo. Integration-style tests (the propagation_runner live-DB SKIP LOCKED walk, the cross-repo audit-kind registry walk) all silently skipped, so coverage reflected only the pure-unit slice.ci.yml's proven-green services pattern:postgres:16-alpine,redis:7-alpine,mongo:6with health checks.TEST_DATABASE_URL,TEST_REDIS_URL,TEST_POSTGRES_CUSTOMERS_URL,TEST_MONGO_URI, plusINSTANT_API_REPOfor the CLAUDE.md rule-18 cross-repo gate.api/internal/db/migrations/), then worker-ownedworker/sql/*.sqlon top — matches whatmake test-db-updoes for an integrated test run.../apisocoverage_registry_test.go::findApiRepoRootresolves and the audit-kind drift detection participates in coverage.continue-on-error: trueso a single flaky test never drops the coverage artifact — codecov still ingestscoverage.out.Per CLAUDE.md rule 23 (the local gate must equal CI) — coverage should run the same hermetic suite ci.yml does.
Test plan
Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com
🤖 Generated with Claude Code