2019-09-15 12:36:17 +00:00
|
|
|
name: 'Lint And Test'
|
|
|
|
|
|
|
|
on:
|
2020-11-13 04:34:41 +00:00
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2022-03-27 17:12:16 +00:00
|
|
|
- next
|
2019-09-15 12:36:17 +00:00
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- master
|
2022-03-27 17:12:16 +00:00
|
|
|
- next
|
2019-09-15 12:36:17 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
lint:
|
|
|
|
name: Lint Check
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2022-03-05 08:02:23 +00:00
|
|
|
- uses: actions/checkout@v3
|
2022-02-26 08:01:10 +00:00
|
|
|
- uses: actions/setup-node@v3
|
2022-03-27 17:12:16 +00:00
|
|
|
with:
|
|
|
|
node-version: 'lts/*'
|
2019-09-15 12:36:17 +00:00
|
|
|
- name: Install Packages
|
|
|
|
run: npm install
|
|
|
|
- name: Lint Code
|
|
|
|
run: npm run lint:ci
|
|
|
|
|
|
|
|
run_tests:
|
|
|
|
name: Unit Tests
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os:
|
|
|
|
- ubuntu-latest
|
|
|
|
- windows-latest
|
|
|
|
node:
|
2022-03-27 17:12:16 +00:00
|
|
|
- 14
|
|
|
|
- 16
|
|
|
|
- 17
|
2019-09-15 12:36:17 +00:00
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
steps:
|
2022-03-05 08:02:23 +00:00
|
|
|
- uses: actions/checkout@v3
|
2022-02-26 08:01:10 +00:00
|
|
|
- uses: actions/setup-node@v3
|
2019-09-15 12:36:17 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node }}
|
|
|
|
- name: Install Packages
|
|
|
|
run: npm install
|
|
|
|
- name: Run Tests
|
|
|
|
run: npm run test:ci
|