Skip to content

Commit 1ff6b40

Browse files
authored
Set up tests and coverage reporting in CI
1 parent 746b07a commit 1ff6b40

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

.github/workflows/test.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
on:
2+
pull_request:
3+
push:
4+
branches:
5+
- master
6+
name: Test
7+
jobs:
8+
test:
9+
env:
10+
working-directory: ./src
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Install Node 15.x
14+
uses: actions/setup-node@v1
15+
with:
16+
node-version: 15.x
17+
- name: Checkout code
18+
uses: actions/checkout@v2
19+
- name: Test and Create Coverage Data
20+
working-directory: ${{ env.working-directory }}
21+
run: npm ci && npm run test-coveralls
22+
- name: Coveralls
23+
uses: coverallsapp/github-action@v1.1.2
24+
with:
25+
github-token: ${{ secrets.github_token }}
26+
path-to-lcov: ${{ env.working-directory }}/coverage/lcov.info
27+
base-path: ${{ env.working-directory }}

0 commit comments

Comments
 (0)