Skip to content

Commit bff929f

Browse files
author
Muhammad Rehan Alam
committed
update github action
1 parent 19ccac1 commit bff929f

1 file changed

Lines changed: 14 additions & 6 deletions

File tree

.github/workflows/test.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,34 @@
1-
name: Authlete Demo App Tests
1+
name: CI / Tests & Coverage
22

3+
# Trigger workflow
34
on:
45
push:
6+
branches: [main, develop] # Run on main & develop
7+
pull_request: # Run on all PRs targeting any branch
58
branches: ["*"]
6-
pull_request:
79

810
jobs:
911
test:
1012
runs-on: ubuntu-latest
13+
1114
steps:
1215
- uses: actions/checkout@v3
16+
1317
- name: Setup Node.js
1418
uses: actions/setup-node@v3
1519
with:
1620
node-version: 20
21+
cache: "npm"
22+
1723
- name: Install dependencies
1824
run: npm ci
19-
- name: Run Tests
20-
run: npm run test
25+
26+
- name: Run Vitest
27+
run: npm run test -- --coverage
28+
2129
- name: Upload Coverage
22-
if: success()
23-
uses: actions/upload-artifact@v3
30+
uses: actions/upload-artifact@v4
31+
if: always()
2432
with:
2533
name: coverage-report
2634
path: coverage/

0 commit comments

Comments
 (0)