Skip to content

test(vrt): improve snapshot reliability - #8332

Open
joshblack wants to merge 4 commits into
mainfrom
ci/update-flaky-tests
Open

test(vrt): improve snapshot reliability#8332
joshblack wants to merge 4 commits into
mainfrom
ci/update-flaky-tests

Conversation

@joshblack

@joshblack joshblack commented Aug 24, 2026

Copy link
Copy Markdown
Member

Update our snapshot reliability by using reduce motion by default and waiting for fonts to load before visiting a page / snapshotting it.

Changelog

New

Changed

  • Update our playwright config to use reduced motion by default
  • Update our visit helper so that it waits for fonts to load on the page
  • Update snapshots with these changes

Removed

Rollout strategy

  • None; if selected, include a brief description as to why

@changeset-bot

changeset-bot Bot commented Aug 24, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 33f0322

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

@joshblack joshblack added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Aug 24, 2026
@github-actions
github-actions Bot temporarily deployed to storybook-preview-8332 August 24, 2026 18:46 Inactive
@github-actions github-actions Bot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Aug 24, 2026
@github-actions
github-actions Bot temporarily deployed to storybook-preview-8332 August 24, 2026 19:04 Inactive
@joshblack joshblack added skip changeset This change does not need a changelog integration-tests: skipped manually Changes in this PR do not require an integration test labels Aug 24, 2026
@joshblack joshblack changed the title test: use reduced motion by default test(vrt): improve snapshot reliability Aug 24, 2026
@joshblack
joshblack marked this pull request as ready for review August 24, 2026 20:26
Copilot AI lite review requested due to automatic review settings August 24, 2026 20:26
@joshblack
joshblack requested a review from a team as a code owner August 24, 2026 20:26
@joshblack
joshblack requested a review from jonrohan August 24, 2026 20:26

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.

Pull request overview

This PR aims to improve Playwright VRT snapshot reliability by enforcing reduced motion by default and ensuring Storybook pages wait for fonts to load before screenshots are taken.

Changes:

  • Sets reduced motion globally in the Playwright test configuration.
  • Updates the Storybook visit helper to wait for document.fonts.ready before continuing.
  • Removes redundant per-test reduced motion media emulation calls.
Show a summary per file
File Description
playwright.config.ts Attempts to enable reduced motion by default for all Playwright tests.
e2e/test-helpers/storybook.ts Waits for font loading readiness before proceeding with image waits/snapshots.
e2e/components/TooltipV2.test.ts Removes per-test reduced motion emulation now intended to be global.
e2e/components/SelectPanel.test.ts Removes per-test reduced motion emulation now intended to be global (including forced-colors cases).

Review details

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 4/13 changed files
  • Comments generated: 1
  • Review effort level: Lite

Comment thread playwright.config.ts
@joshblack
joshblack enabled auto-merge August 24, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration-tests: skipped manually Changes in this PR do not require an integration test skip changeset This change does not need a changelog staff Author is a staff member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants