Repository navigation
test(websearch): stabilize Brave timeout coverage - #1959
Merged
kevincodex1 merged 1 commit intoJul 14, 2026
Merged
Conversation
Contributor
📝 WalkthroughWalkthroughThe Brave provider test file now acquires the shared mutation lock once during module setup and releases it after all tests. Per-test cleanup only restores environment variables and the captured global fetch implementation. ChangesBrave provider test synchronization
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 6 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (6 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
kevincodex1
approved these changes
Jul 14, 2026
This was referenced Jul 16, 2026
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
process.envandglobalThis.fetchonly while owning that lock.Why
PR #1939's Node 22 smoke run failed the target test at 5936.95ms, then passed when that job was retried without a code change. The asynchronous
beforeEachlock wait was included in the test's deadline; a roughly five-second queue wait plus the deliberate one-second provider timeout caused the flake.Validation
bun test src/tools/WebSearchTool/providers/brave.test.ts(10 pass)bun run test:full: all Brave tests pass, including the target at ~1.00s. It retains the 24 unrelated failures reproduced unchanged on clean upstream main.git diff --checkNotes
The complete baseline failures are the stale startup-provider override, PowerShell/git commit-governance, and full-plan-instructions cases; they reproduce identically from upstream main.
security:pr-scanis not reported because it compares against the stale fork-origin baseline and scans unrelated upstream history.Summary by CodeRabbit