Skip to content

test(functional): upgrade Playwright and fix Sync tests for keys_optional#20791

Open
vbudhram wants to merge 1 commit into
mainfrom
fxa-13647
Open

test(functional): upgrade Playwright and fix Sync tests for keys_optional#20791
vbudhram wants to merge 1 commit into
mainfrom
fxa-13647

Conversation

@vbudhram

@vbudhram vbudhram commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Because

  • The functional suite was pinned to Playwright 1.44.1; upgrading to 1.61.1 (Firefox 151) keeps the browser engine current and unblocks newer test APIs.
  • Firefox 151 / decoupled Sync (keys_optional) changed signin routing, breaking several Sync and OAuth functional tests.

This pull request

  • Upgrades @playwright/test 1.44.1 → 1.61.1 (packages/functional-tests/package.json, yarn.lock).
  • Bumps the fxa-circleci CI images v9 → v10 (.circleci/config.yml) so the functional-test-runner ships the matching browsers.
  • Updates keys_optional mocks to be capability-based (Sync not decoupled) rather than browser-version-based in vpnIntegration.spec.ts, passkeyPasswordFallback.spec.ts, and the syncV3/* specs.
  • Adds waitForOauthPage() in relier.ts so email-first/AAL2 nav waits for the settled /oauth page, not the intermediate /authorization redirect.
  • Adds respondToWebChannelMessageAlways() in layout.ts for flows that re-dispatch fxa_status.
  • Adds gotoSyncSession() in lib/sync-helpers.ts to abstract /pair navigation across Sync tests.

Issue that this pull request solves

Closes: https://mozilla-hub.atlassian.net/browse/FXA-13647

Checklist

  • My commit is GPG signed.
  • If applicable, I have modified or added tests which pass locally.
  • I have added necessary documentation (if appropriate).
  • I have verified that my changes render correctly in RTL (if appropriate).
  • I have manually reviewed all AI generated code.

Other information

Requires the -v10 CI image (ci-functional-test-runner-v10) to be published before functional tests pass — built via the update-ci-image branch / force-deploy-fxa-ci-images. Verify by re-running the "Firefox Functional Tests - Playwright (PR)" job once -v10 is in the registry.

@vbudhram vbudhram force-pushed the fxa-13647 branch 3 times, most recently from a3887da to 648cca0 Compare June 30, 2026 17:29
@vbudhram vbudhram marked this pull request as ready for review June 30, 2026 17:50
@vbudhram vbudhram requested a review from a team as a code owner June 30, 2026 17:50
@vbudhram vbudhram force-pushed the fxa-13647 branch 2 times, most recently from 4cf760a to c67bd52 Compare June 30, 2026 19:36
…th tests

Because:
- Playwright 1.61.1 (Firefox 151) surfaced timing flakes in email-first OAuth
  flows, and the keys_optional Sync tests needed updating for decoupled Sync.

This commit:
- Upgrades Playwright to 1.61.1 and fixes the Sync tests for keys_optional.
- Waits for the settled /oauth page in the relier email-first and AAL2 nav
  helpers rather than the intermediate /authorization redirect.
- Adds respondToWebChannelMessageAlways for flows that re-dispatch fxa_status,
  and frames the no-keys_optional mocks as capability-based (Sync not decoupled).
- Hardens fillOutEmailFirstForm to retry the email fill until the submit button
  enables, fixing an email-first re-mount race that left it disabled.
- Converts the CMS Sync tests to page-object helpers (fillOutEmailFirstForm,
  fillOutPasswordForm, connectAnotherDevice) instead of raw locators.
- Bumps the fxa-circleci CI images v9 -> v10 so the functional-test-runner ships
  the Playwright 1.61.1 browsers, and documents the image-update process in
  .circleci/README.md.
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.

1 participant