File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -11,19 +11,27 @@ jobs:
11
11
test :
12
12
name : Test
13
13
runs-on : ubuntu-latest
14
+ strategy :
15
+ fail-fast : false
16
+ matrix :
17
+ go :
18
+ - ' ^1.18'
19
+ - ' ^1.19'
14
20
steps :
15
21
- name : Check out code into the Go module directory
16
- uses : actions/checkout@v2
17
- - uses : actions/setup-go@v2
22
+ uses : actions/checkout@v3
23
+ - uses : actions/setup-go@v3
18
24
with :
19
- go-version : ' ^1.18'
25
+ go-version : ${{ matrix.go }}
26
+ cache : true
20
27
- name : Declare some variables
21
28
id : vars
22
29
run : |
23
30
echo "::set-output name=coverage_txt::${RUNNER_TEMP}/coverage.txt"
24
31
- name : Test Coverage (pkg)
25
32
run : go test ./... -race -coverprofile=${{ steps.vars.outputs.coverage_txt }}
26
33
- name : Upload coverage
34
+ if : ${{ matrix.go == '^1.19' }}
27
35
uses : codecov/codecov-action@v2
28
36
with :
29
37
files : ${{ steps.vars.outputs.coverage_txt }}
You can’t perform that action at this time.
0 commit comments