-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (39 loc) · 1.07 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: test
on: [ push, pull_request ]
jobs:
test:
name: Node v${{ matrix.node }}
strategy:
fail-fast: false
matrix:
node: [ '16', '18', '20', '22' ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
# - uses: denoland/setup-deno@v1
# with:
# deno-version: v1.x
- name: Setup NodeJS
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
cache: npm
- name: Install NodeJS dependencies
run: npm ci
- name: Run linter test
run: npm run lint
- name: Run circular dependency test
run: npm run check
- name: Run compile test
run: npm run compile
- name: Run unit tests
run: npm run citest
env:
NODE_OPTIONS: "--max_old_space_size=4096"
- name: Send coverage to Coveralls
uses: coverallsapp/github-action@v2
# Run only once
if: ${{ matrix.node == '20' }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}