Skip to content

Run Components E2E tests in Chrome container - #70689

Merged
richlander merged 5 commits into
mainfrom
users/richlander/components-e2e-chrome-container
Nov 24, 2026
Merged

richlander merged 5 commits into
mainfrom
users/richlander/components-e2e-chrome-container

Conversation

@richlander

@richlander richlander commented Nov 18, 2026 •

Copy link
Copy Markdown
Member

Run Components E2E tests in Chrome container

  • You've read the Contributor Guide and Code of Conduct.
  • You've included unit or integration tests for your change, where applicable.
  • You've included inline docs for your change, where applicable.
  • There's an open issue for the PR that you are making. If you'd like to propose a new feature or change, please open an issue to discuss the change or find an existing issue.

Run Components E2E tests in the Azure Linux 4 Chrome container

Description

Run the shared Components browser E2E job in an Azure Linux 4 prerequisites container instead of the 1ES Ubuntu 22.04 VM. The image provides Chrome for Testing and matching ChromeDriver through TEST_CHROME_BINARY and CHROMEWEBDRIVER, avoiding browser downloads during test execution.

The prerequisites image and its Node libatomic dependency fix have been published:

Update the existing E2E cases to preserve their intended assertions without depending on older ICU data, implicit viewport geometry, or navigation-lock registration timing. Shipping framework behavior, package pins, and NativeAOT ABI requirements are unchanged.

  • Accept equivalent AM/PM separator spacing in culture-sensitive comparisons, keeping other formatting and invariant input values exact. Do not pin ICU.
  • Use Selenium's native scroll action before dragging so source and target are visible before pointerdown, rather than scrolling during the drag.
  • Click a known outside paragraph to dismiss QuickGrid's column-options popup instead of the table's clipped in-view center.
  • Wait for existing readiness signals before navigation, including both locks in the two-lock case. Wait for the removed lock's DOM to disappear before navigating after disposal.

The evidence, same-source Ubuntu control, and remaining qualification are tracked in #70767. ICU-sensitive tests already passed all 12 Server/WASM and en-US/fr-FR rows in CI run 1693856; that run also identified the remaining browser-test failures addressed by this follow-up.

Validation

Local validation used the published Azure Linux image at digest sha256:42d8a12504aa39a3c6e336a43937320a7086ad87701dd7b5d1e1c7cc6a8ddd30, Chrome 158.0.8127.36, and the default small viewport. Commands ran from the isolated /repo mount after source ./activate.sh. Test applications were Release/untrimmed (TestTrimmedApps=false).

Dependency-aware build: passed, exit 0, zero warnings/errors.

dotnet build src/Components/test/E2ETest/Microsoft.AspNetCore.Components.E2ETests.csproj --no-restore -c Release -p:UseMonoRuntime=false -p:UseIisNativeAssets=false -p:TestTrimmedApps=false -m:2 -v:q

Scoped formatting verification: passed, exit 0.

dotnet format whitespace --folder /repo/src/Components/test/E2ETest/Tests --include EventTest.cs QuickGridTest.cs RoutingTest.cs --verify-no-changes --verbosity quiet

Targeted Selenium tests: passed, exit 0; 21 passed, zero failed/skipped. Complete TRX parsed: all expected case names and execution/definition IDs were present and unique. The 12 globalization preservation rows include every en-US/fr-FR combination on both Server and WASM.

dotnet test src/Components/test/E2ETest/Microsoft.AspNetCore.Components.E2ETests.csproj --no-build -c Release -p:UseMonoRuntime=false -p:UseIisNativeAssets=false -p:TestTrimmedApps=false --filter 'FullyQualifiedName~DragDrop_CanTrigger|FullyQualifiedName~CanCloseColumnOptionsByBlurring|FullyQualifiedName~NavigationLock_CanBlockNavigation_ThenContinue|FullyQualifiedName~NavigationLock_RemovesLock_WhenDisposed|FullyQualifiedName~NavigationLock_HistoryNavigationWorks_AfterRefresh|FullyQualifiedName~CanSetCultureAndParseCultureSensitiveNumbersAndDates|FullyQualifiedName~CanSetCultureAndParseCultureInvariantNumbersAndDatesWithInputFields|FullyQualifiedName~CanSetCultureAndParseCultureInvariantNumbersAndDatesWithFormComponents' --logger 'trx;LogFileName=targeted-green.trx' --results-directory /evidence/chrome-e2e-repair/targeted-green

Native live-Blazor probes also verified the disputed producer paths. Before the repair, two-lock trials failed 7/10 and disposal trials failed 5/10 without readiness synchronization; the synchronized versions passed 10/10 each. Pre-drag scrolling produced real dragstart without scrolling after pointerdown in 10/10 trials per platform. Original assertions remain intact; no events or callbacks were injected. Owned helpers were stopped.

These results establish the local untrimmed boundary, not full-suite CI success. Qualification of the new PR head in consumer CI remains pending.

Fixes #70767

Note

This pull request description was generated with GitHub Copilot.

richlander and others added 2 commits November 17, 2026 20:47
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander

Copy link
Copy Markdown
Member Author

/azp run aspnetcore-components-e2e

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

The new image affects both public and internal E2E jobs, but its publication and full pipeline compatibility remain unverified; only a Chrome smoke test is reported.

No open issues 🎉

What changed in this PR

Moves the shared Components browser E2E job from the 1ES Ubuntu 22.04 VM configuration to an Azure Linux 4 container with pinned browser tooling.

Changes:

  • Replaces use1ESUbuntu with the Chrome-enabled prereqs container.
  • Uses the image’s pinned Chrome for Testing and matching chromedriver to avoid browser downloads during test execution.

The pipeline depends on the image from dotnet/dotnet-buildtools-prereqs-docker#1825 being published.

File Description
.azure/​pipelines/​jobs/​components-e2e-test-job.yml Configures the shared Components E2E job to use the Chrome prereqs container.

Review effort: Balanced

Refs #70767. Keep invariant formats exact and tolerate only equivalent AM/PM separator spaces across host and WASM ICU data.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander
richlander requested a review from a team as a code owner November 22, 2026 02:31
@PureWeen

Copy link
Copy Markdown
Member

/review

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Source-only review of frozen head a5eab590ab8b4c6857227d14a953121897843f25.

One P2 candidate remains inline as unresolved: source proves assertion-only AM/PM spacing normalization and a raw Selenium input path, but the relevant container ICU output, Selenium/Chrome character handling, and old-vs-new runtime outcome are not available in the frozen evidence. This is advisory, not runtime proof.

Existing feedback: No equivalent frozen issue, review, or inline comment was found. Review 6008611417 only notes general image publication/pipeline uncertainty; comments 7052625072, 7052628595, and 7073474943 are pipeline invocation/status or review activation.

Guide completion: docs/CrossCuttingGuidance.md and docs/BlazorComponentsGuidance.md completed their in-scope source checks with gpt-5.6-sol; execution of CI/tests/browsers and security assessment were explicitly excluded. The pipeline template accepts and forwards container in public and internal branches; no source-visible parameter mismatch was found.

DISCARDED
  • NormalizeAmPmSpacing is narrow: it changes only U+00A0/U+202F between a digit and literal AM/PM, so it does not broadly mask date content or arbitrary whitespace.
  • default-build.yml supports the new container parameter in both public and internal jobs while retaining the default Azure Linux pool.
  • The tests remain in the established Components Selenium E2E layer, retain polling assertions, and exercise displayed values rather than helper internals.
  • No public API, production runtime, lifecycle, rendering, navigation, interop, disposal, forms, trimming/AOT, resource-lifetime, or security-sensitive default behavior is changed by the frozen diff.

Provenance and boundary: Version-2 frozen bundle; merge base/base tip d3483989953ae3cccd773aea5ea04cb0c7198531; trusted guidance commit d3483989953ae3cccd773aea5ea04cb0c7198531. No target code, test, browser, CI, or container was executed. Container image contents/publication and runtime ICU/Selenium behavior remain uncovered. Tracked Git bytes only; symlink, submodule, and LFS targets are inert. Feedback posted after bundle preparation is not observable.

Generated by ASP.NET Core Pull Request Review for #70689 · copilot · gpt56 · 180.1 AIC · ⌖ 8.52 AIC · ⊞ 20.3K
Comment /review to run again

input.ReplaceText(new DateTime(2000, 1, 2).ToString(cultureInfo));
input.SendKeys("\t");
Browser.Equal(new DateTime(2000, 1, 2).ToString(cultureInfo), () => display.Text);
Browser.Equal(NormalizeAmPmSpacing(new DateTime(2000, 1, 2).ToString(cultureInfo)), () => NormalizeAmPmSpacing(display.Text));

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

[P2] [UNRESOLVED] Normalize date/time text before Selenium input

The assertion now normalizes U+00A0/U+202F spacing, but the value passed to ReplaceText at line 58 remains the raw DateTime.ToString(cultureInfo) result, and ReplaceText forwards it unchanged to Selenium SendKeys. If the new container emits either spacing character and Chrome cannot type it, the change event can retain the prior value and this post-edit assertion can still fail.

Why unresolved: Frozen source does not establish that this Azure Linux 4 image emits U+00A0/U+202F for the tested en-US value, how its Selenium/Chrome versions handle that character, or that the merge-base environment has a different observable outcome.

Minimal repro: run the en-US CanSetCultureAndParseCultureSensitiveNumbersAndDates row in the configured container, confirm the formatted 2000-01-02 value contains U+00A0/U+202F, then inspect the input/display after ReplaceText and tab.

If confirmed, normalize the typed value too, for example:

Suggested change
Browser.Equal(NormalizeAmPmSpacing(new DateTime(2000, 1, 2).ToString(cultureInfo)), () => NormalizeAmPmSpacing(display.Text));
input.ReplaceText(NormalizeAmPmSpacing(new DateTime(2000, 1, 2).ToString(cultureInfo)));
input.SendKeys("\t");
Browser.Equal(NormalizeAmPmSpacing(new DateTime(2000, 1, 2).ToString(cultureInfo)), () => NormalizeAmPmSpacing(display.Text));

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Checked this against the exact configured AL4 Chrome image and the latest CI results. The proposed failure is not reproduced:

  • The exact-image formatting probe confirms ICU 77.1 formats the en-US value as 1/2/2000 12:00:00\u202FAM (U+202F before AM).
  • ReplaceText forwards the formatted string unchanged to Selenium SendKeys.
  • On head cce1d33230a28ae08dd0f7c0844c491169908864, all 12 globalization rows passed in E2E build 1695925: Server/WASM × en-US/fr-FR × the three culture-sensitive/invariant scenarios. This includes both en-US CanSetCultureAndParseCultureSensitiveNumbersAndDates rows.
  • The post-edit assertions require the bound date to change from 1985-03-04 to 2000-01-02. Normalizing only AM/PM spacing cannot make an unchanged prior date satisfy that assertion. The invariant-input scenarios additionally assert the actual input value is 2000-01-02.

This supports successful input and binding of U+202F with the configured browser/driver, not a blanket claim about U+00A0 or every browser version. The numeric-separator workaround alone does not establish that the current date/time path fails. I am leaving the typed values unchanged unless a faithful reproduction demonstrates otherwise; the current evidence does not substantiate this as a P2 blocker.

Scroll before native drag, click outside QuickGrid options explicitly, and await navigation-lock readiness and removal. Preserve existing assertions and browser defaults. Refs #70767.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander
richlander added this pull request to stack #70771 November 22, 2026 22:28
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander

Copy link
Copy Markdown
Member Author

CI investigation for head cce1d33230a28ae08dd0f7c0844c491169908864: all failures identified in the latest run also occur on main; no PR-only failure remains identified.

Failure Evidence on main
Main CI: Helix monitor reports No Helix jobs were submitted by this stage in any attempt Build 1695870, exact merged main commit 5d27468e60d852db6e6fb9f1e5f7bd291e6640f6
Template CI: same Helix-monitor failure Build 1695823, the same exact main commit
Already-quarantined InitialIndex_RetainsTargetWhenPreviousItemExpandsThenHomeEndTakeOver(useProvider: True) Main build 1695310, same case and assertion at VirtualizationTest.cs:6939
Already-quarantined NavigationException_InAsyncContext_DoesNotBecomeUnobservedTaskException Main builds 1695145, 1695310, and 1695735, same assertion at RedirectionTest.cs:306

The latest Components E2E run 1695925 passed all unquarantined tests: Server 1,487 passed / 0 failed / 1 skipped; client/WASM 1,135 passed / 0 failed / 4 skipped. CancelsOutdatedRefreshes_Async passed on both platforms; its separately reproduced synchronization race remains tracked in #70767.

The Helix submission tasks succeeded and actually submitted six main-CI jobs and three template jobs, despite the monitors reporting none. All previously pending work items have now finished with exit code 0. This establishes work-item completion, not successful Azure test-result publication; the monitor checks remain red. Build Analysis/Insights are downstream red checks, not additional test failures.

Detailed investigation: #70767 (comment)

No migration-specific blocker remains identified. Review approval and maintainer acceptance or recovery of the main-reproducing monitor failures are still needed.

@richlander

Copy link
Copy Markdown
Member Author

/ba-g "Unrelated failures"

@richlander
richlander enabled stacked auto-merge (squash) November 24, 2026 00:52
@richlander
richlander merged commit a6110c2 into main Nov 24, 2026
31 checks passed
@richlander
richlander deleted the users/richlander/components-e2e-chrome-container branch November 24, 2026 00:56
@github-actions

Copy link
Copy Markdown
Contributor

✅ No documentation PR was created.

Confidence that documentation is needed: 3%

No docs needed: test and CI infrastructure change only (E2E tests in Chrome container); no public API, defaults, or behavior changes. Signals: no_signal.

Documentation surfaces considered

  • Conceptual article: Not required — Changes limited to CI pipeline and E2E tests; no user-visible behavior.
  • Migration guidance: Not required — No upgrade action for users.
  • Breaking change: Not required — No compatibility impact; test/CI only.

This branch was previously deployed

1 inactive deployment
copilot-pat-pool — cce1d332 Deployed Nov 24, 2026 by richlander via conclusion #446
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.

Track Components E2E portability across newer Linux images

4 participants