-
Notifications
You must be signed in to change notification settings - Fork 24.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[standards] Migrate "androidTest" JS from Haste to path-based requires #24813
Conversation
The files in `ReactAndroid/src/androidTest/js` use Haste names; this commit migrates them to use path-based imports. This helps us move RN towards standard path-based requires. All the requires in `androidTest` have been rewritten to use relative requires. Test Plan: Run lint, Flow, and Android tests: ``` node cli.js bundle --platform android --dev true --entry-file ReactAndroid/src/androidTest/js/TestBundle.js --bundle-output ReactAndroid/src/androidTest/assets/AndroidTestBundle.js buck install ReactAndroid/src/androidTest/buck-runner:instrumentation-tests ```
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code analysis results:
eslint
found some issues. Runyarn lint --fix
to automatically fix problems.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cpojer is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
const React = require('react'); | ||
const {NativeModules, Text} = require('react-native'); | ||
|
||
const {Recording: RecordingModule} = NativeModules; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be InitialPropsRecordingModule
.
I am fixing it internally, just commenting here for posterity.
This pull request was successfully merged by @ide in cd9adda. When will my fix make it into a release? | Upcoming Releases |
Summary
The files in
ReactAndroid/src/androidTest/js
use Haste names; this commit migrates them to use path-based imports. This helps us move RN towards standard path-based requires. All the requires inandroidTest
have been rewritten to use relative requires.Changelog
[General] [Changed] - Migrate "androidTest" JS from Haste to path-based requires
Test Plan
Run lint, Flow, and Android tests:
Also run CI.