Skip to content

Commit dfb39a5

Browse files
committed
use latest CI actions and run on each PR
1 parent 022186e commit dfb39a5

File tree

2 files changed

+9
-20
lines changed

2 files changed

+9
-20
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ indent_style = space
2121
indent_size = 2
2222

2323
# Matches the exact files either package.json or .travis.yml
24-
[{package.json,.travis.yml}]
24+
[{package.json,*.yml}]
2525
indent_style = space
2626
indent_size = 2

.github/workflows/js_test.yml

Lines changed: 8 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,21 @@
11
name: Test
22

3-
on: [push]
3+
on: [push, pull_request]
44

55
jobs:
66
test:
77
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
node-version: [ 18, 20, 22 ]
811
steps:
9-
- uses: actions/checkout@v1
10-
- name: Cache
11-
id: cache
12-
uses: actions/cache@v1.0.0
13-
with:
14-
path: node_modules
15-
key: ${{ runner.OS }}-build-${{ hashFiles('**/package-lock.json') }}
16-
restore-keys: |
17-
${{ runner.OS }}-build-${{ env.cache-name }}-
18-
${{ runner.OS }}-build-
19-
${{ runner.OS }}-
12+
- uses: actions/checkout@v4
2013
- name: Use Node.js ${{ matrix.node-version }}
21-
uses: actions/setup-node@v1
14+
uses: actions/setup-node@v4
2215
with:
23-
node-version: 12
16+
node-version: ${{ matrix.node-version }}
17+
cache: 'npm'
2418
- name: Install Dependencies
25-
if: steps.cache.outputs.cache-hit != 'true'
2619
run: npm ci
27-
env:
28-
CI: true
2920
- name: npm test
3021
run: npm test
31-
env:
32-
CI: true

0 commit comments

Comments
 (0)