inline-critical/.github/workflows/test.yml
2020-05-20 07:07:57 +02:00

42 lines
887 B
YAML

name: Tests
on: [push, pull_request]
env:
CI: true
jobs:
run:
name: Node ${{ matrix.node }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
node: [10, 12]
os: [ubuntu-latest, windows-latest]
steps:
- name: Clone repository
uses: actions/checkout@v1
with:
fetch-depth: 5
- name: Set Node.js version
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- run: node --version
- run: npm --version
- name: Install npm dependencies
run: npm ci
- name: Run tests
run: npm test
- name: Run Coveralls
uses: coverallsapp/github-action@master
if: startsWith(matrix.os, 'ubuntu') && matrix.node == 10
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'