Fix HelloWorld Jest preset after react-native/jest-preset removal#57491
Closed
cipolleschi wants to merge 1 commit into
Closed
Fix HelloWorld Jest preset after react-native/jest-preset removal#57491cipolleschi wants to merge 1 commit into
cipolleschi wants to merge 1 commit into
Conversation
The react-native/jest-preset.js redirect was removed in #57481, but private/helloworld still referenced 'preset: react-native' in its Jest config, breaking 'yarn test' in the test_ios_helloworld CI job with: Validation Error: Module react-native should have jest-preset.js ... Migrate HelloWorld to the standalone @react-native/jest-preset package, matching the documented migration path.
|
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this in D111215532. |
cortinico
approved these changes
Jul 9, 2026
cortinico
left a comment
Contributor
There was a problem hiding this comment.
Review automatically exported from Phabricator review in Meta.
|
@cipolleschi merged this pull request in 7d2ef78. |
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.
Summary
#57481 removed the
react-native/jest-preset.jsredirect module (and thereact-native/jest-presetpublic export), but the in-repoprivate/helloworldapp still referencedpreset: 'react-native'in its Jest config. This breaksyarn testin thetest_ios_helloworldCI job (which cascade-cancels the rest of the iOS matrix and turns the e2e retryreportjobs red):This migrates HelloWorld to the standalone
@react-native/jest-presetpackage — the documented migration path (seepackages/jest-preset/README.md).Changes
private/helloworld/jest.config.js:preset: 'react-native'→preset: '@react-native/jest-preset'private/helloworld/package.json: add@react-native/jest-presetdevDependency (0.87.0-main, matching the sibling@react-native/*packages)Changelog:
[Internal] [Fixed] - Fix HelloWorld Jest preset after
react-native/jest-presetremovalTest Plan
cd private/helloworld && yarn testresolves the preset and runs (previously failed with the validation error above).test_ios_helloworldjob.