Skip to content

Commit

Permalink
Merge pull request #7 from kunnapool/tests-and-lint
Browse files Browse the repository at this point in the history
Workflow: Tests and lint checks
  • Loading branch information
kunnapool authored Feb 25, 2022
2 parents 3f75e5e + 3b4bddc commit 5fae543
Show file tree
Hide file tree
Showing 2 changed files with 8,735 additions and 8,991 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/run-tests-and-lint-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Run Tests and Lint checks

on:
push:
branches: [master] # only run the check when the PR is merged

jobs:
runTests:
runs-on: ${{ matrix.runEnv }}
strategy:
matrix:
runEnv: [ubuntu-latest, windows-latest, macOS-latest]

steps:
- uses: actions/checkout@v2

- name: Use Node.js 16.0.0
uses: actions/setup-node@v1
with:
node-version: 16.0.0

- name: Install packages
run: npm install

- name: Run Tests
run: ./node_modules/grunt/bin/grunt coveralls

eslint:
needs: runTests # if code is failing tests, lint and prettier don't matter
runs-on: ${{ matrix.runEnv }}
strategy:
matrix:
runEnv: [ubuntu-latest, windows-latest, macOS-latest]
checks:
[npx prettier --check ./, ./node_modules/eslint/bin/eslint.js ./]

steps:
- uses: actions/checkout@v2

- name: Use Node.js 16.0.0
uses: actions/setup-node@v1
with:
node-version: 16.0.0

- name: Install packages
run: npm install

- name: Run checks
run: ${{ matrix.checks }}
Loading

0 comments on commit 5fae543

Please sign in to comment.