fix: stabilize algorithm picker e2e.#940
Open
jonathanp-okta wants to merge 3 commits into
Open
Conversation
|
Preview URL https://next-jwt-h8r4yyddo-okta.vercel.app |
|
Preview URL https://next-jwt-pa8wkgag1-okta.vercel.app |
jonathanp-okta
marked this pull request as ready for review
July 22, 2026 19:36
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
By submitting a PR to this repository, you agree to the terms within the Auth0 Code of Conduct. Please see the contributing guidelines for how to create and submit a high-quality PR for this repo.
Description
Fixes a race condition in the Playwright E2E tests for the decoder and encoder "generate JWT example" workflows.
The algorithm picker performs asynchronous WebCrypto capability checks for P-521, Ed25519, and Ed448. Previously, each check updated component state independently. These updates rebuilt the options passed to
react-selectwhile Playwright was interacting with the open menu. As a result, Playwright could resolve an option and then lose it when the option was replaced in the DOM, producingelement is not stableandelement was detached from the DOMtimeouts.The fix runs the capability checks concurrently with
Promise.alland applies their results in a single state update. The algorithm picker exposes its loading state througharia-busy, allowing the E2E setup to wait until capability detection is complete before opening the menu. The option locators remain scoped to the visiblelistbox.The PR also corrects the Playwright trace artifact path in the test workflow. Traces are written under
test-results, notplaywright-report, so failed CI runs will now upload the generated trace files correctly.Scope is limited to algorithm-picker initialization, the related decoder and encoder E2E setup hooks, and CI trace collection. Selection behavior, algorithm ordering, labels, and styling are unchanged.
References
N/A
Testing
Automated E2E verification: all 28 affected Chromium decoder and encoder algorithm-example tests passed serially with one worker.
Type and editor verification: no diagnostics were reported in the modified component or E2E files.
Manual verification: confirmed that the algorithm picker opens and selects examples correctly in both Decoder and Encoder views.
CI should verify the same workflows across Chromium and Firefox without relying on retries.
This change adds test coverage for new/changed/fixed functionality
Checklist