Repository navigation
[release/17.0] Make E2E notification cleanup deterministic - #22292
Jose Perez Rodriguez (joperezr) merged 1 commit into
Conversation
There was a problem hiding this comment.
🔵 Needs a closer look
Windows E2E and VS Code-hosted bridge validation remain pending, leaving the backport’s ability to clear real notifications in the target host unverified.
No open issues 🎉
What changed in this PR
Backports #21565 to release/17.0 to make VS Code extension E2E notification cleanup independent of toast positioning and mouse interaction. The change targets test reliability without changing shipped diagnostic-log actions or notification UI.
Changes:
- Adds an E2E bridge command that invokes VS Code’s
notifications.clearAll. - Uses the command in bounded notification cleanup and the Python debugging setup scenario.
- Adds regression coverage for unclickable notifications and bridge command dispatch.
Actual Windows E2E validation and the VS Code-hosted bridge test remain pending, as documented in the PR.
| File | Description |
|---|---|
extension/src/types/extensionApi.ts |
Adds the clear-all notification control command type. |
extension/src/testing/e2eStateFileBridge.ts |
Dispatches the new command to VS Code. |
extension/src/test/notificationWaitForMessage.test.ts |
Tests bridge-based cleanup with an unclickable toast. |
extension/src/test/e2eStateFileBridge.test.ts |
Tests dispatch to notifications.clearAll. |
extension/src/test-e2e/helpers/vscode.ts |
Replaces toast clicking with bridge-based cleanup. |
extension/src/test-e2e/edgeCases.e2e.test.ts |
Uses shared cleanup after asserting the Python setup message. |
Review effort: Balanced
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 22292Or
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 22292" |
Tests selector0 / 101 PR test projects · 2 PR jobs, from 6 changed files. Selected PR test projects (0 / 101)none — no PR-gated .NET test projects run for this change. Selected PR jobs (2)
How these were chosen — grouped by what changedJob reasons
Selection computed for commit |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
6e0984c
into
release/17.0
Description
Backport of #21565 to
release/17.0(source commitaf4527806f2e09424b40e72ab80895fffe82b02f).The release branch's Windows diagnostic-log E2E scenario fails while clearing a notification: the toast's clear-button click at
(11,11)is intercepted by the VS Code titlebar. This prevents the scenario from reliably exercising the current CLI and AppHost log actions.This exact six-file backport uses the existing E2E control bridge to invoke VS Code's
notifications.clearAll, rather than clicking the toast. Cleanup remains bounded; the feature assertions remain intact. Behavioral tests cover an unclickable toast and bridge command dispatch. No skips, quarantine, added retries, timeout increases, dependency changes, or workflow changes.Related: #22241; original source issue #21742.
Failure evidence: release/17.0 push CI, attempt 1, Windows diagnostic-logs job, commit
a509f094e0ee87d17dc0e1cc9bca84f7ca2623da. That source failure branch determines the PR base. The earlier backport #22009 is closed and unmerged; this PR does not modify or reopen it.Customer Impact
Release-branch CI can fail during notification cleanup rather than testing diagnostic-log behavior. This is an E2E reliability fix, not a change to the shipped log actions or notification UI. Screenshots are not applicable to this test-control change.
Testing
The following results were obtained in a prior isolated Linux validation on the exact target commit above with this exact source patch; they are reused here, not presented as new executions:
extension/unless noted)corepack yarn run compile-testscorepack yarn exec mocha -- --ui tdd out/test/notificationWaitForMessage.test.js --grep 'dismisses notifications through VS Code clear-all'notifications[0].dismiss()restored and the new test retained: 0 passed, 1 failed withElementNotInteractableError. This is a behavioral regression proof, not an actual Windows reproduction.corepack yarn run compile-e2ecorepack yarn run compile-testsfollowed bycorepack yarn exec mocha -- --ui tdd out/test/notificationWaitForMessage.test.jscorepack yarn exec eslint -- src/test-e2e/helpers/vscode.ts src/test-e2e/edgeCases.e2e.test.ts src/test/e2eStateFileBridge.test.ts src/test/notificationWaitForMessage.test.ts src/testing/e2eStateFileBridge.ts src/types/extensionApi.tsgit diff --exit-code && git diff --cached --check(repository root)For this PR preparation,
git cherry-pick --no-commit af4527806f2e09424b40e72ab80895fffe82b02fandgit diff --cached --checkpassed again on the same target.Current-head validation: CI run 43689787525 completed successfully at
58e2a9ea9fe792491c87dce7a723b389f3b816b7. Windows diagnostic-logs passed 2/2, edge-cases 6/6, tree-actions 7/7, and VS Code-hosted unit tests passed 4,153 with 9 pre-existing pending tests. The requiredFinal Resultscheck passes. Independent review of this exact head passed; there are no unresolved review threads.Attempt 1 required workflow approval and ran no tests. Attempt 2 exposed existing release-branch tree URL readiness, global fake-timer, and ARM64 packaging failures; attempt 3 completed successfully. The earlier failures remain part of the CI record, not evidence of first-attempt reliability or branch recovery. Notification cleanup does not change resource URL snapshots; the timer tests use the pre-existing global fake clock. Separate fixes already on main address those tree/timer races and are not folded into this backport.
The existing test-selection map routes
extension/**to extension unit and E2E jobs; no routing change is needed. The current release tip6a7a7c49dc62640bc28cb6f9e613422540380206has noextension/changes relative to the tested base. Human review and shiproom approval remain required. A later eligible scheduled/push CI run exercising the merged fix is required before declaring branch recovery.Risk
Low: the change is confined to E2E notification cleanup and its existing test-control bridge. It preserves bounded cleanup and the diagnostic-log assertions. Windows and hosted validation passed at the PR head.
Regression?
Unknown: the failure and matching main-branch fix are established, but the introducing version or commit is not.
Checklist
<remarks />and<code />elements on your triple slash comments?🤖 AspireAssistant