Skip to content

[AI-3713] Build the money-refused call test on router timings - #2342

Closed
kanat wants to merge 1 commit into
mainfrom
kanat/fix-main-2277-build
Closed

kanat wants to merge 1 commit into
mainfrom
kanat/fix-main-2277-build

Conversation

@kanat

@kanat kanat commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator

Why

go vet -tags integration ./internal/api fails on main: scheduled_unpaid_test.go (from #2277) assigns scheduledPhoneWindow and scheduledCallLimit. #2293 made both constants and moved the values to the router's phoneWindow and callLimit fields, so every Integration (router) job fails at compile time.

How it works

TelnyxUnpaidSuite.callOn now saves, sets and restores s.router.phoneWindow and s.router.callLimit, the way shortCalls in scheduled_phone_test.go does. Values (deliveryWait, 2*deliveryWait) and the cleanup are unchanged; no assertion changed.

Changes

  • acceleration/internal/api/scheduled_unpaid_test.go: 3 lines.

Validation

  • go vet -tags integration ./... in acceleration/: clean.
  • go test -tags integration ./internal/api -run TestTelnyxUnpaidSuite -count=1: ok (101 s).
  • Mutations: ring window set to 1 ms fails 6 call tests; call limit set to 1 ms fails 3 call tests. Dropping either set alone passes, because those calls end by the agent hanging up and the real values (90 s, 10 min) are only upper bounds the tests never reach, so the value cannot be observed.

🤖 Generated with Claude Code

#2277 assigned scheduledPhoneWindow and scheduledCallLimit, which #2293 made
constants and moved to the router's phoneWindow and callLimit. The call
helper now sets the router's own fields, with the same values and the same
cleanup, so the api integration tests compile again.

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

@kanat kanat left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VERDICT: GO

Reviewed fdf38f4 on origin/main 6d3cb55 (up to date, no merge needed).

  • The change swaps the three scheduledPhoneWindow / scheduledCallLimit assignments for s.router.phoneWindow / s.router.callLimit in callOn. It uses the same values (deliveryWait, 2*deliveryWait) and the same save/restore cleanup, in the shape of shortCalls in scheduled_phone_test.go. No assertion changed.
  • go vet -tags integration ./... in acceleration/ is clean on the head.
  • No other assignment to scheduledPhoneWindow, scheduledCallLimit or scheduledReplyWindow remains on main (all three are consts, read only at server.go:617-619). No DeliveryRetries or FinishRetries var remains (SetFinishRetries is a method).
  • TestTelnyxUnpaidSuite passes on the merged tree (94.8 s). Mutation: setting the ring window to 1 ms fails 5 call tests, so the new fields reach the code under test. Dropping either set still passes, because the real windows are upper bounds these tests never reach (author's note, same as the 1 ms limit case); not a new rule.
  • Draft PR, so no integration CI yet; it runs at gh pr ready.

No findings.

@kanat
kanat marked this pull request as ready for review November 24, 2026 08:34
@kanat

kanat commented Nov 25, 2026

Copy link
Copy Markdown
Collaborator Author

Closing as a duplicate: #2341 (AI-3712) landed the same change on main (callOn sets s.router.phoneWindow/s.router.callLimit). Merging this branch into main now changes nothing.

@kanat kanat closed this Nov 25, 2026
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