Skip to content

fix(tests): stabilize flaky React Native metrics onboarding test#112000

Open
JoshuaKGoldberg wants to merge 1 commit intomasterfrom
fix/flaky-react-native-metrics-spec-v2
Open

fix(tests): stabilize flaky React Native metrics onboarding test#112000
JoshuaKGoldberg wants to merge 1 commit intomasterfrom
fix/flaky-react-native-metrics-spec-v2

Conversation

@JoshuaKGoldberg
Copy link
Copy Markdown
Member

@JoshuaKGoldberg JoshuaKGoldberg commented Apr 1, 2026

This test is slow because the component does asynchronous dynamic importing. That can take a long time under CI load, along with added cumulative time with two userEvent.click interactions.

This fix adds more asynchronous waiting assertions within the test:

  • An explicit wait for any loading indicator to be done before asserting on text contents
  • Switching the first lookup in each group from synchronous getBy to asynchronous findBy

Fixes ENG-7206

Made with Cursor

@linear-code
Copy link
Copy Markdown

linear-code bot commented Apr 1, 2026

@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Apr 1, 2026
@JoshuaKGoldberg JoshuaKGoldberg added the Frontend: Rerun Flaky Tests Known flaky tests should be run many times, just to be safe. label Apr 1, 2026
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as ready for review April 1, 2026 15:56
@JoshuaKGoldberg JoshuaKGoldberg requested a review from a team as a code owner April 1, 2026 15:56
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Comment thread static/app/gettingStartedDocs/react-native/metrics.spec.tsx
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as draft April 7, 2026 14:09
@JoshuaKGoldberg JoshuaKGoldberg changed the base branch from fix/flaky-test-rerun-infra to master April 7, 2026 14:09
@JoshuaKGoldberg JoshuaKGoldberg force-pushed the fix/flaky-react-native-metrics-spec-v2 branch from 0d768cc to 9cf0d3b Compare April 7, 2026 14:14
@JoshuaKGoldberg JoshuaKGoldberg removed the Frontend: Rerun Flaky Tests Known flaky tests should be run many times, just to be safe. label Apr 7, 2026
@JoshuaKGoldberg JoshuaKGoldberg removed the request for review from a team April 7, 2026 14:21
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as ready for review April 7, 2026 14:27
@JoshuaKGoldberg JoshuaKGoldberg requested a review from a team April 7, 2026 14:50
@JoshuaKGoldberg JoshuaKGoldberg added the Frontend: Rerun Flaky Tests Known flaky tests should be run many times, just to be safe. label Apr 8, 2026
@JoshuaKGoldberg JoshuaKGoldberg requested a review from antonis April 14, 2026 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Frontend: Rerun Flaky Tests Known flaky tests should be run many times, just to be safe. Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant