Merge pull request #107 from CharlieC3/master #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GH Pages | |
on: | |
push: | |
branches: | |
- 'master' | |
jobs: | |
gh-pages: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 12.x | |
- name: Cache node_modules | |
id: cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.npm | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- name: Install dependencies | |
run: npm install | |
- name: Run tests | |
run: npm run test | |
- name: Generate coverage report | |
run: npm run report-lcov | |
- name: Upload to codecov | |
uses: codecov/codecov-action@v1 | |
- name: Publish test coverage report | |
uses: JamesIves/[email protected] | |
with: | |
branch: gh-pages | |
folder: coverage/lcov-report |