diff --git a/.github/workflows/devtools_regression_tests.yml b/.github/workflows/devtools_regression_tests.yml index 4fe3d0ccb0..1fd18d1727 100644 --- a/.github/workflows/devtools_regression_tests.yml +++ b/.github/workflows/devtools_regression_tests.yml @@ -123,7 +123,7 @@ jobs: - name: Display structure of build run: ls -R build - run: ./scripts/ci/download_devtools_regression_build.js ${{ matrix.version }} --replaceBuild - - run: node ./scripts/jest/jest-cli.js --build --project devtools --release-channel=experimental --reactVersion ${{ matrix.version }} --ci=github + - run: node ./scripts/jest/jest-cli.js --build --project devtools --release-channel=experimental --reactVersion ${{ matrix.version }} --ci run_devtools_e2e_tests_for_versions: name: Run DevTools e2e tests for versions diff --git a/.github/workflows/runtime_build_and_test.yml b/.github/workflows/runtime_build_and_test.yml index 2413ed3521..7186e60f9b 100644 --- a/.github/workflows/runtime_build_and_test.yml +++ b/.github/workflows/runtime_build_and_test.yml @@ -141,7 +141,7 @@ jobs: path: "**/node_modules" key: ${{ runner.arch }}-${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }} - run: yarn install --frozen-lockfile - - run: yarn test ${{ matrix.params }} --ci=github --shard=${{ matrix.shard }} + - run: yarn test ${{ matrix.params }} --ci --shard=${{ matrix.shard }} # ----- BUILD ----- build_and_lint: @@ -170,7 +170,7 @@ jobs: path: "**/node_modules" key: ${{ runner.arch }}-${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }} - run: yarn install --frozen-lockfile - - run: yarn build --index=${{ matrix.worker_id }} --total=20 --r=${{ matrix.release_channel }} --ci=github + - run: yarn build --index=${{ matrix.worker_id }} --total=20 --r=${{ matrix.release_channel }} --ci env: CI: github RELEASE_CHANNEL: ${{ matrix.release_channel }} @@ -248,7 +248,7 @@ jobs: merge-multiple: true - name: Display structure of build run: ls -R build - - run: yarn test --build ${{ matrix.test_params }} --shard=${{ matrix.shard }} --ci=github + - run: yarn test --build ${{ matrix.test_params }} --shard=${{ matrix.shard }} --ci process_artifacts_combined: name: Process artifacts combined diff --git a/.github/workflows/runtime_fuzz_tests.yml b/.github/workflows/runtime_fuzz_tests.yml index dac4dd095a..54b6d9eb3d 100644 --- a/.github/workflows/runtime_fuzz_tests.yml +++ b/.github/workflows/runtime_fuzz_tests.yml @@ -32,5 +32,5 @@ jobs: shell: bash - name: Run fuzz tests run: |- - FUZZ_TEST_SEED=$RANDOM yarn test fuzz --ci=github - FUZZ_TEST_SEED=$RANDOM yarn test --prod fuzz --ci=github + FUZZ_TEST_SEED=$RANDOM yarn test fuzz --ci + FUZZ_TEST_SEED=$RANDOM yarn test --prod fuzz --ci diff --git a/scripts/jest/jest-cli.js b/scripts/jest/jest-cli.js index 70d4d04b2b..b68ecaae28 100644 --- a/scripts/jest/jest-cli.js +++ b/scripts/jest/jest-cli.js @@ -91,8 +91,8 @@ const argv = yargs ci: { describe: 'Run tests in CI', requiresArg: false, - type: 'choices', - choices: ['circleci', 'github'], + type: 'boolean', + default: false, }, compactConsole: { alias: 'c', @@ -308,12 +308,7 @@ function getCommandArgs() { args.push('--useStderr'); } - // CI Environments have limited workers. - if (argv.ci === 'circleci') { - args.push('--maxWorkers=2'); - } - - if (argv.ci === 'github') { + if (argv.ci === true) { args.push('--maxConcurrency=10'); } @@ -368,7 +363,7 @@ function main() { const envars = getEnvars(); const env = Object.entries(envars).map(([k, v]) => `${k}=${v}`); - if (argv.ci !== 'github') { + if (argv.ci !== true) { // Print the full command we're actually running. const command = `$ ${env.join(' ')} node ${args.join(' ')}`; console.log(chalk.dim(command)); diff --git a/scripts/rollup/build-all-release-channels.js b/scripts/rollup/build-all-release-channels.js index 5615b5949c..8c1ca3ced1 100644 --- a/scripts/rollup/build-all-release-channels.js +++ b/scripts/rollup/build-all-release-channels.js @@ -76,8 +76,8 @@ const argv = yargs.wrap(yargs.terminalWidth()).options({ ci: { describe: 'Run tests in CI', requiresArg: false, - type: 'choices', - choices: ['circleci', 'github'], + type: 'boolean', + default: false, }, type: { describe: `Build the given bundle type. (${Object.values( @@ -109,7 +109,7 @@ const argv = yargs.wrap(yargs.terminalWidth()).options({ }).argv; async function main() { - if (argv.ci === 'github') { + if (argv.ci === true) { buildForChannel(argv.releaseChannel, argv.total, argv.index); switch (argv.releaseChannel) { case 'stable': { @@ -138,7 +138,7 @@ async function main() { // Then merge the experimental folder into the stable one. processExperimental // will have already removed conflicting files. // - // In CI, merging is handled automatically by CircleCI's workspace feature. + // In CI, merging is handled by the GitHub Download Artifacts plugin. mergeDirsSync(experimentalDir + '/', stableDir + '/'); // Now restore the combined directory back to its original name diff --git a/scripts/rollup/stats.js b/scripts/rollup/stats.js index 1a33c7ed0d..d0fbce7108 100644 --- a/scripts/rollup/stats.js +++ b/scripts/rollup/stats.js @@ -18,7 +18,7 @@ const currentBuildResults = { }; function saveResults() { - if (process.env.CI === 'github') { + if (process.env.CI === true) { mkdirp.sync('build/sizes'); fs.writeFileSync( join('build', 'sizes', `bundle-sizes-${process.env.NODE_INDEX}.json`),