mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/42906 Makes way to relocate repo E2E testing + Verdaccio logic under `scripts/e2e/`. The contents of this script are minimal and are better located with `rn-tester-e2e`. Changelog: [Internal] Reviewed By: cipolleschi Differential Revision: D53516117 fbshipit-source-id: e7e50af0383788f2219da190bf921ea93a6455eb
17 lines
582 B
JavaScript
17 lines
582 B
JavaScript
/**
|
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
const SUPPORTED_PLATFORMS = ['ios', 'android'];
|
|
|
|
if (process.argv.length !== 3 || !SUPPORTED_PLATFORMS.includes(process.argv[2])) {
|
|
throw new Error(`Invalid platform. Supported platforms are: ${SUPPORTED_PLATFORMS.join(', ')}`);
|
|
}
|
|
|
|
const platform = process.argv[2];
|
|
const { execSync } = require('child_process');
|
|
execSync(`E2E_DEVICE=${platform} jest --runInBand`, { stdio: 'inherit' });
|