-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
read pnpm version from
package.json
and update node.js in CI
- Loading branch information
1 parent
41441c0
commit 82da63c
Showing
4 changed files
with
31 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,25 +23,27 @@ runs: | |
steps: | ||
- name: Setup pnpm | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 7.12.1 | ||
|
||
- name: Setup Node.js | ||
uses: actions/[email protected] | ||
with: | ||
node-version: ${{ inputs.node-version }} | ||
cache: pnpm | ||
|
||
- name: Configure corepack | ||
if: ${{ inputs.enable-corepack == 'true' }} | ||
- name: Upgrade corepack | ||
if: ${{ inputs.enable-corepack == 'true' && inputs.node-version == '16' }} | ||
shell: bash | ||
# Forcibly upgrade our available version of corepack. | ||
# The bundled version in node 16 has known issues. | ||
# Prepends the npm bin dir so that it is always first. | ||
run: | | ||
npm install --force --global corepack@latest | ||
npm config get prefix >> $GITHUB_PATH | ||
corepack enable | ||
- name: Configure corepack | ||
if: ${{ inputs.enable-corepack == 'true' }} | ||
shell: bash | ||
run: corepack enable | ||
|
||
- name: pnpm install | ||
id: install | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,8 +29,6 @@ env: | |
RUST_BACKTRACE: 0 | ||
NEXT_TELEMETRY_DISABLED: 1 | ||
TEST_CONCURRENCY: 6 | ||
# pnpm version should match to what upstream next.js uses | ||
PNPM_VERSION: 7.24.3 | ||
DATADOG_API_KEY: ${{ secrets.DD_KEY_TURBOPACK }} | ||
DATADOG_TRACE_NEXTJS_TEST: "true" | ||
DD_ENV: "ci" | ||
|
@@ -72,11 +70,15 @@ jobs: | |
path: ./* | ||
key: ${{ inputs.version }}-${{ github.sha }}-${{ github.run_id }}-${{ github.run_attempt}}-${{ github.run_number }} | ||
fail-on-cache-miss: true | ||
|
||
- name: Enable corepack and install yarn | ||
run: | | ||
corepack enable | ||
corepack prepare --activate [email protected] | ||
- name: Run test/development | ||
run: | | ||
ls $NEXT_TEST_SKIP_RETRY_MANIFEST | ||
npm i -g pnpm@$PNPM_VERSION && pnpm --version | ||
npm i -g yarn | ||
sudo npx playwright install-deps && pnpm playwright install | ||
NEXT_TEST_MODE=dev node run-tests.js -g ${{ matrix.group }}/3 -c ${TEST_CONCURRENCY} --test-pattern '^(test\/(development|e2e|unit)|packages\/.*\/src\/.*)/.*\.test\.(js|jsx|ts|tsx)$' | ||
ls test/turbopack-test-junit-report | ||
|
@@ -85,6 +87,7 @@ jobs: | |
env: | ||
# marker to parse log output, do not delete / change. | ||
NEXT_INTEGRATION_TEST: true | ||
|
||
- name: Upload test reports artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
|
@@ -109,16 +112,21 @@ jobs: | |
path: ./* | ||
key: ${{ inputs.version }}-${{ github.sha }} | ||
fail-on-cache-miss: true | ||
|
||
- name: Enable corepack and install yarn | ||
run: | | ||
corepack enable | ||
corepack prepare --activate [email protected] | ||
- name: Run test/production | ||
run: | | ||
npm i -g pnpm@$PNPM_VERSION && pnpm --version | ||
npm i -g yarn | ||
sudo npx playwright install-deps && pnpm playwright install | ||
NEXT_TEST_MODE=start node run-tests.js -g ${{ matrix.group }}/5 -c ${TEST_CONCURRENCY} --test-pattern '^(test\/(production|e2e))/.*\.test\.(js|jsx|ts|tsx)$' | ||
ls test/turbopack-test-junit-report | ||
continue-on-error: true | ||
env: | ||
NEXT_INTEGRATION_TEST: true | ||
|
||
- name: Upload test reports artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
|
@@ -143,16 +151,21 @@ jobs: | |
path: ./* | ||
key: ${{ inputs.version }}-${{ github.sha }} | ||
fail-on-cache-miss: true | ||
|
||
- name: Enable corepack and install yarn | ||
run: | | ||
corepack enable | ||
corepack prepare --activate [email protected] | ||
- name: Run test/integration | ||
run: | | ||
npm i -g pnpm@$PNPM_VERSION && pnpm --version | ||
npm i -g yarn | ||
sudo npx playwright install-deps && pnpm playwright install | ||
node run-tests.js -g ${{ matrix.group }}/12 -c ${TEST_CONCURRENCY} --test-pattern '^(test\/integration)/.*\.test\.(js|jsx|ts|tsx)$' | ||
ls test/turbopack-test-junit-report | ||
continue-on-error: true | ||
env: | ||
NEXT_INTEGRATION_TEST: true | ||
|
||
- name: Upload test reports artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -336,8 +336,6 @@ jobs: | |
# work out of box. We should take another stab at it later. | ||
- name: Setup Pnpm | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 7.2.1 | ||
|
||
- name: Make sure pnpm always has a cache | ||
shell: bash | ||
|
@@ -845,9 +843,7 @@ jobs: | |
- name: Setup Node.js | ||
uses: ./.github/actions/setup-node | ||
with: | ||
# TODO: update to Node 18. Currently fails because the node-canvas dependency doesn't compile for node 18 | ||
# Did not spend too much time investigating so it could be an easy fix. | ||
node-version: 16 | ||
node-version: 18 | ||
|
||
- name: Build benchmarks for tests | ||
timeout-minutes: 120 | ||
|
@@ -912,9 +908,7 @@ jobs: | |
- name: Setup Node.js | ||
uses: ./.github/actions/setup-node | ||
with: | ||
# TODO: update to Node 18. Currently fails because the node-canvas dependency doesn't compile for node 18 | ||
# Did not spend too much time investigating so it could be an easy fix. | ||
node-version: 16 | ||
node-version: 18 | ||
|
||
- name: Build benchmarks for tests | ||
timeout-minutes: 120 | ||
|