2020-02-20 13:59:00 -05:00
|
|
|
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
|
|
|
|
|
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
|
|
|
|
|
|
2019-12-20 14:55:35 -08:00
|
|
|
name: Node.js CI
|
2019-07-29 09:38:23 -07:00
|
|
|
|
2020-02-12 13:26:01 -05:00
|
|
|
on:
|
|
|
|
|
push:
|
|
|
|
|
branches: [ master ]
|
|
|
|
|
pull_request:
|
|
|
|
|
branches: [ master ]
|
2019-07-29 09:38:23 -07:00
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
build:
|
2019-08-06 16:37:30 -07:00
|
|
|
|
2019-07-29 09:38:23 -07:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
2019-08-12 05:50:58 -07:00
|
|
|
strategy:
|
|
|
|
|
matrix:
|
2020-01-12 08:33:58 +00:00
|
|
|
node-version: [10.x, 12.x]
|
2019-08-12 05:50:58 -07:00
|
|
|
|
2019-08-06 16:37:30 -07:00
|
|
|
steps:
|
2019-12-24 14:22:22 -08:00
|
|
|
- uses: actions/checkout@v2
|
2019-08-12 05:50:58 -07:00
|
|
|
- name: Use Node.js ${{ matrix.node-version }}
|
2019-08-02 10:30:20 -04:00
|
|
|
uses: actions/setup-node@v1
|
2019-07-29 09:38:23 -07:00
|
|
|
with:
|
2019-08-14 14:05:28 -04:00
|
|
|
node-version: ${{ matrix.node-version }}
|
2020-01-29 16:34:28 -05:00
|
|
|
- run: npm ci
|
2019-11-12 11:06:49 -05:00
|
|
|
- run: npm run build --if-present
|
|
|
|
|
- run: npm test
|
2019-08-16 10:19:02 -07:00
|
|
|
env:
|
|
|
|
|
CI: true
|