-
-
Notifications
You must be signed in to change notification settings - Fork 12
54 lines (41 loc) · 1012 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: pi-gen-action-unit-tests
on:
push:
branches:
- main
paths-ignore:
- '**.md'
- 'renovate.json'
pull_request:
jobs:
npm-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # fetch full history for Git tests
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- run: npm ci
- run: npm test
- uses: codecov/codecov-action@v4
if: failure() || success()
with:
files: coverage/clover.xml,coverage/lcov.info
flags: unittests
token: ${{ secrets.CODECOV_TOKEN }}
- run: npm run lint
- run: npm run format-check
- run: npm run update-readme
- name: Ensure no Git diff
run: |
GIT_STATUS=$(git status -s)
echo $GIT_STATUS
test -z "$GIT_STATUS"
shellcheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ludeeus/action-shellcheck@master