Skip to content

Commit

Permalink
Add GitHub Workflow for tests. fixes #1333
Browse files Browse the repository at this point in the history
  • Loading branch information
ogonkov authored and fdintino committed Dec 27, 2020
1 parent aa9e5b9 commit de9dc67
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 12 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Tests

on:
push:
branches:
- master
- develop
pull_request:
branches:
- master
paths:
- '**/*.js'
- 'package.json'

jobs:
tests:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest]
node-version: [11.x, 10.x, 8.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- uses: actions/cache@v2
id: cache-node-modules
with:
path: node_modules
key: ${{ matrix.os }}-node-${{ matrix.node-version }}-${{ hashFiles('**/package.json') }}
restore-keys: |
${{ matrix.os }}-node-${{ matrix.node-version }}-
- run: npm install
if: steps.cache-node-modules.outputs.cache-hit != 'true'
- run: npm test
- name: Report coverage
if: success()
run: codecov/codecov-action@v1
12 changes: 0 additions & 12 deletions .travis.yml

This file was deleted.

0 comments on commit de9dc67

Please sign in to comment.