mirror of
https://github.com/kou029w/nodejs-hands-on.git
synced 2025-01-18 16:08:05 +00:00
CI: Add Node.js version matrix and caching for improved testing
This commit is contained in:
parent
a3fc8c6700
commit
4206f38fe8
1 changed files with 11 additions and 0 deletions
11
.github/workflows/ci.yml
vendored
11
.github/workflows/ci.yml
vendored
|
@ -3,9 +3,20 @@ on:
|
||||||
push:
|
push:
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
|
name: Node.js v${{ matrix.node-version }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
node-version:
|
||||||
|
- 20
|
||||||
|
- 22
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 15
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||||
|
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4
|
||||||
|
with:
|
||||||
|
node-version: ${{ matrix.node-version }}
|
||||||
|
cache: npm
|
||||||
- name: Install
|
- name: Install
|
||||||
run: npm ci
|
run: npm ci
|
||||||
- name: Test
|
- name: Test
|
||||||
|
|
Loading…
Add table
Reference in a new issue