Skip to content

Commit d8f354b

Browse files
committed
Update github actions.
1 parent 4d23156 commit d8f354b

File tree

1 file changed

+45
-44
lines changed

1 file changed

+45
-44
lines changed

.github/workflows/main.yml

Lines changed: 45 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -8,66 +8,67 @@ jobs:
88
timeout-minutes: 10
99
strategy:
1010
matrix:
11-
node-version: [20.x]
11+
node-version: [22.x]
1212
steps:
13-
- uses: actions/checkout@v2
14-
- name: Use Node.js ${{ matrix.node-version }}
15-
uses: actions/setup-node@v1
16-
with:
17-
node-version: ${{ matrix.node-version }}
18-
- run: npm install
19-
- name: Run eslint
20-
run: npm run lint
13+
- uses: actions/checkout@v4
14+
- name: Use Node.js ${{ matrix.node-version }}
15+
uses: actions/setup-node@v4
16+
with:
17+
node-version: ${{ matrix.node-version }}
18+
- run: npm install
19+
- name: Run eslint
20+
run: npm run lint
2121
test-node:
22-
needs: lint
22+
needs: [lint]
2323
runs-on: ubuntu-latest
2424
timeout-minutes: 10
2525
strategy:
2626
matrix:
27-
node-version: [16.x, 18.x, 20.x]
27+
node-version: [20.x, 22.x]
2828
steps:
29-
- uses: actions/checkout@v2
30-
- name: Use Node.js ${{ matrix.node-version }}
31-
uses: actions/setup-node@v1
32-
with:
33-
node-version: ${{ matrix.node-version }}
34-
- run: npm install
35-
- name: Run test with Node.js ${{ matrix.node-version }}
36-
run: npm run test-node
29+
- uses: actions/checkout@v4
30+
- name: Use Node.js ${{ matrix.node-version }}
31+
uses: actions/setup-node@v4
32+
with:
33+
node-version: ${{ matrix.node-version }}
34+
- run: npm install
35+
- name: Run tests with Node.js ${{ matrix.node-version }}
36+
run: npm run test-node
3737
test-karma:
38-
needs: lint
38+
needs: [lint]
3939
runs-on: ubuntu-latest
4040
timeout-minutes: 10
4141
strategy:
4242
matrix:
43-
node-version: [20.x]
43+
node-version: [22.x]
4444
steps:
45-
- uses: actions/checkout@v2
46-
- name: Use Node.js ${{ matrix.node-version }}
47-
uses: actions/setup-node@v1
48-
with:
49-
node-version: ${{ matrix.node-version }}
50-
- run: npm install
51-
- name: Run karma tests
52-
run: npm run test-karma
45+
- uses: actions/checkout@v4
46+
- name: Use Node.js ${{ matrix.node-version }}
47+
uses: actions/setup-node@v4
48+
with:
49+
node-version: ${{ matrix.node-version }}
50+
- run: npm install
51+
- name: Run karma tests
52+
run: npm run test-karma
5353
coverage:
5454
needs: [test-node, test-karma]
55-
runs-on: ubuntu-latest
5655
timeout-minutes: 10
56+
runs-on: ubuntu-latest
5757
strategy:
5858
matrix:
59-
node-version: [20.x]
59+
node-version: [22.x]
6060
steps:
61-
- uses: actions/checkout@v2
62-
- name: Use Node.js ${{ matrix.node-version }}
63-
uses: actions/setup-node@v1
64-
with:
65-
node-version: ${{ matrix.node-version }}
66-
- run: npm install
67-
- name: Generate coverage report
68-
run: npm run coverage-ci
69-
- name: Upload coverage to Codecov
70-
uses: codecov/codecov-action@v2
71-
with:
72-
file: ./coverage/lcov.info
73-
fail_ci_if_error: true
61+
- uses: actions/checkout@v4
62+
- name: Use Node.js ${{ matrix.node-version }}
63+
uses: actions/setup-node@v4
64+
with:
65+
node-version: ${{ matrix.node-version }}
66+
- run: npm install
67+
- name: Generate coverage report
68+
run: npm run coverage-ci
69+
- name: Upload coverage to Codecov
70+
uses: codecov/codecov-action@v4
71+
with:
72+
file: ./coverage/lcov.info
73+
fail_ci_if_error: true
74+
token: ${{ secrets.CODECOV_TOKEN }}

0 commit comments

Comments
 (0)