File tree 2 files changed +16
-6
lines changed
2 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -24,24 +24,25 @@ jobs:
24
24
- name : Build
25
25
run : go build -v ./...
26
26
27
- - name : Test
28
- run : go test -v -coverprofile=coverage.txt -covermode=atomic ./...
29
-
30
27
- name : govulncheck
31
28
uses : golang/govulncheck-action@v1
32
29
with :
33
30
go-version-input : 1.21
34
31
go-package : ./...
35
32
36
- - shell : bash
33
+ - name : Test
34
+ run : go test -v -coverprofile=coverage.txt -covermode=atomic ./...
35
+
36
+ - name : Codecov upload coverage
37
+ shell : bash
37
38
env :
38
39
CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
40
+ RUN_ID : ${{ github.run_id }}
39
41
run : |
40
42
# Replace `linux` below with the appropriate OS
41
43
# Options are `alpine`, `linux`, `macos`, `windows`
42
44
# You will need to setup the environment variables below in github
43
45
# and the project in codecov.io
44
- go test -v -coverprofile=coverage.txt -covermode=atomic ./...
45
46
curl -Os https://uploader.codecov.io/latest/linux/codecov
46
47
chmod +x codecov
47
- CODECOV_TOKEN= $CODECOV_TOKEN ./codecov
48
+ ./codecov --verbose upload-process --fail-on-error -t $CODECOV_TOKEN -n 'service'-$RUN_ID -F service -f coverage-service.xml
Original file line number Diff line number Diff line change
1
+ package main
2
+
3
+ import (
4
+ "os"
5
+ )
6
+
7
+ func main () {
8
+ os .Stdout .WriteString ("Hello world!\n " )
9
+ }
You can’t perform that action at this time.
0 commit comments