Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
[ghstack-poisoned]
  • Loading branch information
poteto committed Jul 29, 2024
1 parent 6fa8b74 commit 6e29385
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 20 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/devtools_regression_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,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
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/runtime_build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,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:
Expand Down Expand Up @@ -168,7 +168,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 }}
Expand Down Expand Up @@ -246,7 +246,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
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/runtime_fuzz_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
13 changes: 4 additions & 9 deletions scripts/jest/jest-cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -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',
Expand Down Expand Up @@ -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');
}

Expand Down Expand Up @@ -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));
Expand Down
8 changes: 4 additions & 4 deletions scripts/rollup/build-all-release-channels.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,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(
Expand Down Expand Up @@ -110,7 +110,7 @@ const argv = yargs.wrap(yargs.terminalWidth()).options({
}).argv;

async function main() {
if (argv.ci === 'github') {
if (argv.ci === true) {
await buildEverything(argv.index, argv.total);
switch (argv.releaseChannel) {
case 'stable': {
Expand Down Expand Up @@ -139,7 +139,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
Expand Down
2 changes: 1 addition & 1 deletion scripts/rollup/stats.js
Original file line number Diff line number Diff line change
Expand Up @@ -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`),
Expand Down

0 comments on commit 6e29385

Please sign in to comment.