Skip to content

test(api): limits suite writes requests through insertRequest - #2391

Closed
martinmitrevski wants to merge 1 commit into
mainfrom
martinmitrevski/fix-limits-test-insert-request
Closed

martinmitrevski wants to merge 1 commit into
mainfrom
martinmitrevski/fix-limits-test-insert-request

Conversation

@martinmitrevski

Copy link
Copy Markdown
Collaborator

Why

internal/api's integration tests don't build on main, so integration (api) fails for main and for every open PR:

internal/api/limits_test.go:651:39: s.store.Requests.Insert undefined

Two PRs merged 50 minutes apart: #2372 added SelfHostedLimitsSuite.spent, which calls Requests.Insert, and #2377 removed Requests.Insert and moved every other test to the insertRequest helper (server_test.go:40). Main's own run on 09bcd98 shows it: the integration (api) job of Integration (router).

Changes

spent writes through insertRequest, as the 85 calls #2377 moved do. It is the only Requests.Insert call left in acceleration/.

Validation

  • go vet ./... and go vet -tags integration ./... in acceleration/ pass.
  • TestSelfHostedLimitsSuite, the suite that calls spent, passes locally against Postgres 19 and Redis 7 (5 tests).

🤖 Generated with Claude Code

#2372 added SelfHostedLimitsSuite.spent, which called
Requests.Insert, and #2377 removed Requests.Insert and moved every
other test to insertRequest. Both merged, so internal/api's integration
tests no longer build on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@martinmitrevski

Copy link
Copy Markdown
Collaborator Author

Closing: #2386 (83d7b27) already fixed this on main. It writes SelfHostedLimitsSuite.spent through Requests.InsertMany, so the conflict resolves to main's version and leaves nothing to merge. go vet -tags integration ./internal/api/ passes on main at d1416c2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant