Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Run tests on Node.js v16 as well as v20 #1518

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/artifact-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version-file: .nvmrc

# Need root node_modules because certain npm packages like jest are configured for the entire repository and it won't be possible
# without these to just compile the artifacts package
Expand Down Expand Up @@ -79,10 +79,10 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version-file: .nvmrc

# Need root node_modules because certain npm packages like jest are configured for the entire repository and it won't be possible
# without these to just compile the artifacts package
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/audit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version-file: .nvmrc

- name: npm install
run: npm install
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/cache-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version-file: .nvmrc

# In order to save & restore cache from a shell script, certain env variables need to be set that are only available in the
# node context. This runs a local action that gets and sets the necessary env variables that are needed
Expand All @@ -44,7 +44,7 @@ jobs:
npm ci
npm run tsc
working-directory: packages/cache

- name: Generate files in working directory
shell: bash
run: packages/cache/__tests__/create-cache-files.sh ${{ runner.os }} test-cache
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/cache-windows-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ jobs:
run: |
rm "C:\Program Files\Git\usr\bin\tar.exe"

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v1
with:
node-version: 20.x
node-version-file: .nvmrc

# In order to save & restore cache from a shell script, certain env variables need to be set that are only available in the
# node context. This runs a local action that gets and sets the necessary env variables that are needed
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/releases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ jobs:
- name: verify package exists
run: ls packages/${{ github.event.inputs.package }}

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version-file: .nvmrc

- name: npm install
run: npm install
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ jobs:
strategy:
matrix:
runs-on: [ubuntu-latest, macos-latest, windows-latest]
node-version: [16.x, 20.x]
fail-fast: false

runs-on: ${{ matrix.runs-on }}
Expand All @@ -25,10 +26,10 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set Node.js 20.x
- name: Set Node.js version
uses: actions/setup-node@v4
with:
node-version: 20.x
node-version: ${{ matrix.node-version }}

- name: npm install
run: npm install
Expand Down
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v20
Loading