File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Code coverage generation
2
+ on : [push]
3
+ jobs :
4
+ codecov :
5
+ name : Build
6
+ runs-on : ubuntu-latest
7
+ steps :
8
+ - name : Set up Go 1.17
9
+ uses : actions/setup-go@v1
10
+ with :
11
+ go-version : 1.17
12
+
13
+ - name : Check out code into the Go module directory
14
+ uses : actions/checkout@v1
15
+
16
+ - name : Get dependencies
17
+ run : |
18
+ go get -v -t -d ./...
19
+ if [ -f Gopkg.toml ]; then
20
+ curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
21
+ dep ensure
22
+ fi
23
+
24
+ - name : Generate coverage report
25
+ run : |
26
+ go test ./... -coverprofile=coverage.txt -covermode=atomic
27
+
28
+ - name : Upload coverage report
29
+ uses : codecov/codecov-action@v1.0.2
30
+ with :
31
+ token : ${{ secrets.CODECOV_TOKEN }}
32
+ file : ./coverage.txt
33
+ flags : unittests
34
+ name : codecov-umbrella
35
+ fail_ci_if_error : true
36
+ verbose : true
You can’t perform that action at this time.
0 commit comments