Skip to content

test(popover): phase 6 tests for behavior, utils, and a11y#6426

Merged
rubencarvalho merged 8 commits into
ruben/popover-migrationfrom
ruben/test-popover-swc-1993
Jul 8, 2026
Merged

test(popover): phase 6 tests for behavior, utils, and a11y#6426
rubencarvalho merged 8 commits into
ruben/popover-migrationfrom
ruben/test-popover-swc-1993

Conversation

@rubencarvalho

@rubencarvalho rubencarvalho commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Description

Phase 6 (testing) for the Popover migration: play functions for synthetic-input behavior, Playwright tests for native browser dismissal, and unit tests for the shared core/utils.

What's in it

  • Play functions (popover.test.ts): synthetic-input behavior. Property defaults and reflection, ARIA (aria-expanded, aria-haspopup="dialog", aria-controls), click-to-toggle, programmatic close-source, modal scroll-lock and backdrop, focus restoration, and failed showPopover()/showModal() handling.
  • Playwright a11y spec (popover.a11y.spec.ts): ARIA-tree snapshots, plus native light-dismiss (which needs trusted input): Escape and outside-click close-source, modal Escape, and a 3-level nested dismissal-ordering test. Native dismissal cannot run in a play function (see docs(testing): test native dismissal in the Playwright spec, not play functions #6474), so it lives here.
  • Unit tests: resolve-trigger, dismissible-stack, transition, deep-contains.

Notes

Base is ruben/popover-migration (now on main, spectrum-tokens 14.13.1). #6357 (Phase 4+5) is merged, so this diff is the Phase 6 delta only.

Related issue(s)

  • Epic SWC-1993

Accessibility testing checklist

  • Keyboard: Playwright drives trusted Escape and outside-click, asserting close-source and 3-level nested dismissal ordering; aria-expanded toggling is covered by play functions.
  • Screen reader: ARIA-tree snapshots assert the trigger's collapsed dialog control and the open dialog's accessible name (default and modal modes).

@rubencarvalho rubencarvalho requested a review from a team as a code owner June 19, 2026 10:45
@changeset-bot

changeset-bot Bot commented Jun 19, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 644d515

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@rubencarvalho rubencarvalho added ready-for-review Status:Ready for review PR ready for review or re-review. labels Jun 19, 2026
@github-actions

github-actions Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

📚 Branch Preview Links

🔍 Gen1 Visual Regression Test Results

When a visual regression test fails (or has previously failed while working on this branch), its results can be found in the following URLs:

Deployed to Azure Blob Storage: pr-6426

If the changes are expected, update the current_golden_images_cache hash in the circleci config to accept the new images. Instructions are included in that file.
If the changes are unexpected, you can investigate the cause of the differences and update the code accordingly.

@rubencarvalho rubencarvalho changed the base branch from ruben/feat-popover-a11y-styling-swc-1993 to ruben/popover-migration June 19, 2026 11:48
@rubencarvalho rubencarvalho added Status:WIP PR is a work in progress or draft Component:Popover Status:Ready for review PR ready for review or re-review. and removed Status:Ready for review PR ready for review or re-review. Status:WIP PR is a work in progress or draft labels Jul 7, 2026
rubencarvalho added a commit that referenced this pull request Jul 7, 2026
Phase 7 (#6427) was stacked on Phase 6 (#6426), so its squash carried the test
content into popover-migration, leaving #6426 with no diff. Revert popover.test.ts
and popover.a11y.spec.ts to their #6357 state and remove the util test files so
the Phase 6 tests land (and review) via #6426.
@rubencarvalho rubencarvalho force-pushed the ruben/test-popover-swc-1993 branch from e91f4a6 to 0f07ed6 Compare July 7, 2026 16:41
@rubencarvalho rubencarvalho changed the title test(popover): phase 6 — behavior, util, and a11y coverage test(popover): phase 6 tests for behavior, utils, and a11y Jul 7, 2026
…-only fixtures

The a11y run serves Storybook in ci-a11y/build mode, where the dev-only *.test.ts
fixture stories are not indexed, so gotoStory hung to timeout in CI. Point the four
native-dismissal tests at the published anatomy/modal/nested stories (which exist in
every mode) and drop the now-unused render-only fixtures.
@rubencarvalho rubencarvalho merged commit 5758334 into ruben/popover-migration Jul 8, 2026
27 checks passed
@rubencarvalho rubencarvalho deleted the ruben/test-popover-swc-1993 branch July 8, 2026 10:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component:Popover Status:Ready for review PR ready for review or re-review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants