-
Notifications
You must be signed in to change notification settings - Fork 3
44 lines (41 loc) · 979 Bytes
/
ci.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
name: build
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
strategy:
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
node-version: ['12', '>=14']
name: ${{ matrix.platform }} / Node.js v${{ matrix.node-version }}
runs-on: ${{ matrix.platform }}
steps:
# Needed to avoid issues with Prettier
- run: git config --global core.autocrlf false
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: |
npm ci
npm link
env:
CI: true
- name: Run unit tests
run: |
npm run lint
bash -c "scripts/test.sh"
build_all:
if: always()
runs-on: ubuntu-latest
needs: build
steps:
- name: Check build matrix status
if: ${{ needs.build.result != 'success' }}
run: exit 1