Repository navigation
Fix the main CI unit test breaks from the sessions providers double and leaked question carousels - #346643
Merged
Bryan Chen (bryanchen-d) merged 2 commits intoNov 6, 2026
Conversation
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues remain, though tests were not independently rerun.
No open issues 🎉
What changed in this PR
This PR fixes two test-isolation problems behind main CI failures without changing production behavior.
Changes:
- Adds
onDidChangeProviders: Event.Noneto two Sessions provider test doubles to support session action context-key subscriptions. - Registers DOM cleanup for every question carousel created by the test helper, preventing leftover widgets from disrupting later layout tests.
No actionable findings remain. Tests were not independently rerun; WebKit-only carousel layout failures remain outside this PR’s scope.
| File | Description |
|---|---|
src/vs/workbench/contrib/chat/test/browser/widget/chatContentParts/chatQuestionCarouselPart.test.ts |
Removes every created carousel during disposal instead of only the last one. |
src/vs/sessions/contrib/chatWindow/test/browser/sessionsChatWindowProvider.test.ts |
Adds the provider-change event to the service double. |
src/vs/sessions/contrib/chatWindow/test/browser/chatWindowChangesetActions.test.ts |
Imports Event and supplies the missing provider-change event stub. |
Review effort: Balanced
Raymond Zhao (rzhao271)
approved these changes
Nov 6, 2026
Raymond Zhao (rzhao271)
marked this pull request as ready for review
November 6, 2026 20:53
Ross Wollman (rwoll)
approved these changes
Nov 6, 2026
#346419 made sessionAgentMerge observe ISessionsProvidersService.onDidChangeProviders. The chat window test doubles only stubbed getProvider, so binding session action context keys threw 'this.event is not a function' whenever agentMergeActions was loaded in the same renderer. Co-authored-by: Copilot <[email protected]>
Tests that create several carousels removed only the last one in teardown, so the others stayed in the page. Since #346600 they add about 130px above every later fixture, which broke the drag-buffer tests of Sessions - Headers and the compact menu direction tests of Workbench - Titlebar Part on main. Co-authored-by: Copilot <[email protected]>
Bryan Chen (bryanchen-d)
force-pushed
the
copilot/vscode/session-providers-test-doubles
branch
from
November 6, 2026 21:04
a349baf to
d910ebd
Compare
Bryan Chen (bryanchen-d)
deleted the
copilot/vscode/session-providers-test-doubles
branch
November 6, 2026 21:14
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.
Main CI has been red since 493783 (
3bd71c378f). It has 10 Electron and Chromium unit failures on Linux, Windows and macOS, tracked in microsoft/vscode-engineering#4490. There are two separate test breaks.1.
this.event is not a function(Chat window changeset actions, Sessions chat window provider: 6 failures).#346419 (
fbdefe8df36) madesessionAgentMergeobserveISessionsProvidersService.onDidChangeProviders. TheISessionsProvidersServicedoubles inchatWindowChangesetActions.test.tsandsessionsChatWindowProvider.test.tsonly stubgetProvider. So whenagentMergeActionsis loaded in the same renderer, binding the session action context keys throws. The fix addsonDidChangeProviders: Event.Noneto both doubles.2. Sessions - Headers (2) and Workbench - Titlebar Part (2) geometry failures.
These aren't caused by #346419. In
chatQuestionCarouselPart.test.ts, teardown removed only the last carousel a test created. #346600 (83b2d78545b) added tests that create several carousels in a loop, so the extra ones stayed indocument.body. A probe run right after the suite found 2 leftover.chat-question-carousel-containerelements, makingbody131px tall. That pushed every later fixture down, which flips Headers' drag-buffer hit test (blocked: true) and Titlebar's compact-menu direction (opensDownward: false). The fix makescreateWidgetregister the removal of every carousel it creates.The WebKit-only carousel layout failures from #346600 are not part of this PR.
Validation
--runListwithagentMergeActions.test.tsplus the 4 failing suites:this.event--runListwith the carousel suite then Headers and Titlebar:this.eventfailures are gone, and only Headers 2 and Titlebar 2 remain. Proof 493806 on this head is running.tsc --noEmitis clean for the touched files.