diff --git a/.github/workflows/runtime_build.yml b/.github/workflows/runtime_build.yml index a380c2c85c722..e57a153832fb4 100644 --- a/.github/workflows/runtime_build.yml +++ b/.github/workflows/runtime_build.yml @@ -26,7 +26,7 @@ jobs: id: define_release_channels with: script: | - return ['stable', 'experimental']; + return ["stable", "experimental"]; build: name: yarn build @@ -51,12 +51,14 @@ jobs: key: ${{ runner.arch }}-${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }} - run: yarn install --frozen-lockfile - run: yarn build --b=${{ matrix.bundle_type }} --r=${{ matrix.release_channel }} --ci=github + - name: Display structure of build + run: ls -R build - name: Archive build uses: actions/upload-artifact@v4 with: - name: ${{ matrix.bundle_type }}-${{ matrix.release_channel }} + name: ${{ matrix.bundle_type }}_${{ matrix.release_channel }} path: | - build/** + build lint_build: name: yarn lint-build @@ -65,6 +67,7 @@ jobs: matrix: bundle_type: ${{ fromJSON(needs.define_build_params.outputs.bundle_type) }} release_channel: ${{ fromJSON(needs.define_build_params.outputs.release_channel) }} + continue-on-error: true runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -79,9 +82,72 @@ jobs: with: path: "**/node_modules" key: ${{ runner.arch }}-${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }} + - run: yarn install --frozen-lockfile - name: Restore archived build uses: actions/download-artifact@v4 with: - name: ${{ matrix.bundle_type }}-${{ matrix.release_channel }} - - run: yarn install --frozen-lockfile + name: ${{ matrix.bundle_type }}_${{ matrix.release_channel }} + path: build + - name: Display structure of build + run: ls -R build - run: yarn lint-build + + test_build: + name: yarn test-build + needs: build + strategy: + matrix: + test_params: [ + # Intentionally passing these as strings instead of creating a + # separate parameter per CLI argument, since it's easier to + # control/see which combinations we want to run. + -r=stable --env=development, + -r=stable --env=production, + -r=experimental --env=development, + -r=experimental --env=production, + + # Dev Tools + --project=devtools -r=experimental, + + # TODO: Update test config to support www build tests + # - "-r=www-classic --env=development --variant=false" + # - "-r=www-classic --env=production --variant=false" + # - "-r=www-classic --env=development --variant=true" + # - "-r=www-classic --env=production --variant=true" + # - "-r=www-modern --env=development --variant=false" + # - "-r=www-modern --env=production --variant=false" + # - "-r=www-modern --env=development --variant=true" + # - "-r=www-modern --env=production --variant=true" + + # TODO: Update test config to support xplat build tests + # - "-r=xplat --env=development --variant=false" + # - "-r=xplat --env=development --variant=true" + # - "-r=xplat --env=production --variant=false" + # - "-r=xplat --env=production --variant=true" + + # TODO: Test more persistent configurations? + ] + continue-on-error: true + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 18.x + cache: "yarn" + cache-dependency-path: yarn.lock + - name: Restore cached node_modules + uses: actions/cache@v4 + id: node_modules + with: + path: "**/node_modules" + key: ${{ runner.arch }}-${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }} + - run: yarn install --frozen-lockfile + - name: Restore archived build + uses: actions/download-artifact@v4 + with: + path: build-temp + - name: Display structure of build + run: ls -R build-temp + # - run: yarn test --build ${{ matrix.test_params }} --ci=github + diff --git a/packages/react-devtools-shared/src/__tests__/storeStressTestConcurrent-test.js b/packages/react-devtools-shared/src/__tests__/storeStressTestConcurrent-test.js index 472ad31671a76..8dd4ce428438f 100644 --- a/packages/react-devtools-shared/src/__tests__/storeStressTestConcurrent-test.js +++ b/packages/react-devtools-shared/src/__tests__/storeStressTestConcurrent-test.js @@ -16,6 +16,8 @@ describe('StoreStressConcurrent', () => { let store; let print; + jest.setTimeout(15000); + beforeEach(() => { global.IS_REACT_ACT_ENVIRONMENT = true; diff --git a/packages/shared/ReactVersion.js b/packages/shared/ReactVersion.js index 13dd40e747e0d..c215912df2204 100644 --- a/packages/shared/ReactVersion.js +++ b/packages/shared/ReactVersion.js @@ -1,15 +1 @@ -/** - * 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. - */ - -// TODO: this is special because it gets imported during build. -// -// It exists as a placeholder so that DevTools can support work tag changes between releases. -// When we next publish a release, update the matching TODO in backend/renderer.js -// TODO: This module is used both by the release scripts and to expose a version -// at runtime. We should instead inject the version number as part of the build -// process, and use the ReactVersions.js module as the single source of truth. -export default '19.0.0'; +export default '19.0.0-rc-3a600d54b3-20240624'; diff --git a/scripts/rollup/build-ghaction.js b/scripts/rollup/build-ghaction.js index 60871e3e9208c..ce2ee7addb878 100644 --- a/scripts/rollup/build-ghaction.js +++ b/scripts/rollup/build-ghaction.js @@ -846,9 +846,7 @@ async function buildEverything(bundleTypeToBuild) { ); await Promise.all( - bundles.map(([bundle, bundleType]) => { - return createBundle(bundle, bundleType); - }) + bundles.map(([bundle, bundleType]) => createBundle(bundle, bundleType)) ); await Packaging.copyAllShims();