Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48022
Changelog: [internal]
This adds support for Fantom options in tests to configure different aspects of the test execution.
For now, it only supports specifying the mode (dev or opt) so we can try things without having to change the runner (watch mode still works if you change mode :D).
Fantom options are specified as pragmas in the docblock of the test. E.g.:
```
/**
* flow strict-local
* format
* fantom_mode opt
*/
```
We expect this is mostly going to be used for one-time tests and that regular tests won't specify the mode (they'll just run in dev mode).
Maybe we can evolve this in the future to specify that you want a test to be executed in both modes, to ensure the behavior is consistent in dev/prod.
Reviewed By: rshest
Differential Revision: D66597626
fbshipit-source-id: b12325fc2235740cc2a3e0283d6a556091c1794c
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48014
Changelog: [internal]
Just a small refactor in preparation for a following change that will add more usages for these utilities. It also cleans up the runner file which is good too.
Reviewed By: javache
Differential Revision: D66595405
fbshipit-source-id: e734d76006ce937fadd1cb673035db85a3e838dd