Skip to content

Commit

Permalink
Add GitHub Action test
Browse files Browse the repository at this point in the history
Copied from standard/standard, with addition of 16.x
  • Loading branch information
voxpelli committed Jun 14, 2021
1 parent 686c61e commit 8b2602a
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Test

on:
push:
branches: [master]
pull_request:
branches: [master]

jobs:
test:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [10.x, 12.x, 14.x, 16.x]
fail-fast: false

steps:
- name: Checkout project
uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}

- name: Cache Node dependencies
uses: actions/[email protected]
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install

- name: Run tests
run: npm test

0 comments on commit 8b2602a

Please sign in to comment.