Skip to content

Retry only failed Fantom tests instead of full suite on CI#56425

Closed
andrewdacenko wants to merge 1 commit intofacebook:mainfrom
andrewdacenko:export-D100618771
Closed

Retry only failed Fantom tests instead of full suite on CI#56425
andrewdacenko wants to merge 1 commit intofacebook:mainfrom
andrewdacenko:export-D100618771

Conversation

@andrewdacenko
Copy link
Copy Markdown
Contributor

Summary:
Changelog: [Internal]

The Fantom CI retry loop previously re-ran the entire test suite on each attempt. This wastes time and can introduce new flaky failures that weren't in the original run (e.g., a FlatList race condition appearing on attempt 2 but not attempt 1).

This changes the retry logic to use Jest's --onlyFailures flag on attempts 2 and 3, so only the test suites that actually failed get re-run. For example, if 1 out of 99 suites fails with a SIGSEGV, the retry runs just that 1 suite instead of all 99 — reducing retry time from ~80s to seconds.

Differential Revision: D100618771

Summary:
Changelog: [Internal]

The Fantom CI retry loop previously re-ran the entire test suite on each attempt. This wastes time and can introduce new flaky failures that weren't in the original run (e.g., a FlatList race condition appearing on attempt 2 but not attempt 1).

This changes the retry logic to use Jest's `--onlyFailures` flag on attempts 2 and 3, so only the test suites that actually failed get re-run. For example, if 1 out of 99 suites fails with a SIGSEGV, the retry runs just that 1 suite instead of all 99 — reducing retry time from ~80s to seconds.

Differential Revision: D100618771
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Apr 13, 2026
@meta-codesync
Copy link
Copy Markdown

meta-codesync bot commented Apr 13, 2026

@andrewdacenko has exported this pull request. If you are a Meta employee, you can view the originating Diff in D100618771.

@meta-codesync meta-codesync bot closed this in 7d51201 Apr 13, 2026
@facebook-github-tools facebook-github-tools bot added the Merged This PR has been merged. label Apr 13, 2026
@meta-codesync
Copy link
Copy Markdown

meta-codesync bot commented Apr 13, 2026

This pull request has been merged in 7d51201.

@react-native-bot
Copy link
Copy Markdown
Collaborator

This pull request was successfully merged by @andrewdacenko in 7d51201

When will my fix make it into a release? | How to file a pick request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. meta-exported p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants