Skip to content

test(server): stabilize elapsed-budget coverage - #40

Merged
jmgilman merged 1 commit into
masterfrom
test/issue-23-deadline-flake
Aug 25, 2026
Merged

jmgilman merged 1 commit into
masterfrom
test/issue-23-deadline-flake

Conversation

@jmgilman

Copy link
Copy Markdown
Contributor

Summary

  • raise the elapsed-budget test window from 20ms to 2s so a race-instrumented worker reliably reaches the required authorizer call
  • keep every error, deadline, zero-handler-call, and one-authorizer-call assertion unchanged

Discovered while running final validation for #23.

Evidence

The prior 20ms setting failed intermittently because process spawn could consume the budget before authorization. The failure reproduced with -race -count=5. After this change:

  • go test -race . -run '^TestServerExecuteElapsedBudgetAfterAllowPreventsHandler$' -count=5
  • golangci-lint run --config .golangci.yml . --show-stats=false

Review

Bounded review confirmed the old test failed spuriously rather than passing spuriously, the observable contract remains intact, and no assertion was weakened.

@jmgilman
jmgilman merged commit 36f38b0 into master Aug 25, 2026
4 checks passed
@jmgilman
jmgilman deleted the test/issue-23-deadline-flake branch August 25, 2026 22:26
jmgilman added a commit that referenced this pull request Aug 25, 2026
Follow-up review after #33-#40 landed:
- Rewrite the Rego how-to verification against the current stdio
  tutorial; #34 deleted the in-process client it patched.
- Show the literal tools/list wire schemas in the MCP reference
  (inlined field shapes, result: true) and fix the composite example's
  root output shape (field items, not a bare list root).
- Add MaxIntermediateValueBytes to SECURITY.md's limit inventory.
- Make disable-capabilities verification executable-shaped with exact
  inputs and expected tool errors.
- Style repairs on new text: conditions before code, descriptive
  reference voice, removed 'normally'/'common'/'output universe',
  terminology and link fixes.
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