You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug(mq): internal/mq integration tests are selected by name pattern, so a new prefix is silently skipped #692
The Makefile's integration target runs internal/mq's integration-tagged tests (the external NATS broker, //go:build integration files: external_auth_test.go, external_conformance_test.go, external_export_test.go, external_perms_test.go, external_test.go, lease_test.go) by matching test names against a fixed pattern, not by build tag alone:
(Makefile, the second gotestsum invocation for internal/mq, alongside the broader ./tests/integration/... ./internal/mq/natsspike/... ./internal/cache/... run.) Every func Test... currently in those six integration-tagged files does start with one of ExternalNATS, NewNATS, NATSPermissions_Refuse or Leases — confirmed by listing every top-level test in those files and checking each against the pattern, so nothing is silently skipped today. But the selection is by name, not by build tag or package membership: a new integration-tagged test added under internal/mq with a different prefix builds cleanly, passes under a plain go test -tags integration ./internal/mq/..., and is simply never selected by this -run pattern — CI reports the integration job green, and nothing indicates a test was excluded.
Evidence: measured (every current integration-tagged test name in internal/mq matches the pattern, confirmed by listing them) plus inferred (the failure mode for a future test with a different prefix, not reproduced by actually adding one).
This is a structural/latent risk rather than a currently-manifesting bug: nothing is missed right now, but nothing enforces that it stays that way as internal/mq grows.
Reproduce/confirm: add a throwaway //go:build integration test to internal/mq named e.g. func TestMQNATSSomethingNew(...), run make test-integration (or the equivalent Makefile target), and confirm it neither runs nor is reported as skipped.
Activity
feat(mq): external nats broker with sharded, pinned ingest workers (#624