File tree Expand file tree Collapse file tree 1 file changed +21
-16
lines changed Expand file tree Collapse file tree 1 file changed +21
-16
lines changed Original file line number Diff line number Diff line change 1
- name : Unit Tests (Vitest)
2
-
1
+ name : Unit Tests
3
2
on :
4
3
push :
5
4
branches :
6
5
- main
6
+ paths :
7
+ - src/**
7
8
pull_request :
8
9
types : [opened, synchronize, reopened]
9
-
10
10
jobs :
11
- build :
11
+ tests :
12
12
runs-on : ubuntu-latest
13
+ name : Tests
13
14
if : |
14
15
(
15
16
!contains(github.event.head_commit.message, '[skip ci]') &&
16
17
!contains(github.event.head_commit.message, 'version bump')
17
18
)
18
19
steps :
19
- - uses : actions/checkout@v2
20
- - uses : actions/setup-node@v1
20
+ - name : Checkout repository
21
+ uses : actions/checkout@v3
22
+ - name : Install pnpm
23
+ uses : pnpm/action-setup@v2
21
24
with :
22
- node- version : ' 18 '
23
- registry-url : ' https://registry.npmjs.org '
24
-
25
+ version : 8.11
26
+ - name : Install Node
27
+ uses : actions/setup-node@v3
25
28
with :
26
- timezoneLinux : " America/Los_Angeles"
27
- timezoneMacos : " America/Los_Angeles"
28
- timezoneWindows : " Pacific Standard Time"
29
- - run : npm i
30
- - run : npm test
31
-
32
- - uses : actions/upload-artifact@v2
29
+ node-version : 20
30
+ cache : ' pnpm'
31
+ registry-url : ' https://registry.npmjs.org'
32
+ - name : Install dependencies
33
+ run : pnpm install
34
+ - name : Run tests
35
+ run : pnpm test
36
+ - name : Upload artifacts
37
+ uses : actions/upload-artifact@v2
33
38
if : failure()
34
39
with :
35
40
name : unit-tests
You can’t perform that action at this time.
0 commit comments