File tree Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Expand file tree Collapse file tree 2 files changed +49
-0
lines changed File renamed without changes.
Original file line number Diff line number Diff line change 1+ name : Code Coverage
2+
3+ on :
4+ pull_request :
5+ merge_group :
6+ push :
7+ branches :
8+ - main
9+ - master
10+
11+ permissions :
12+ contents : read
13+
14+ jobs :
15+ coverage :
16+ runs-on : ubuntu-latest
17+ steps :
18+ - name : Checkout
19+ uses : actions/checkout@v5
20+ with :
21+ fetch-depth : 1
22+
23+ - name : Install Go
24+ uses : actions/setup-go@v6
25+ with :
26+ go-version : stable
27+
28+ - name : Install Terraform
29+ uses : hashicorp/setup-terraform@v3
30+
31+ - name : Build binaries
32+ run : make build
33+
34+ - name : Verify go.mod is tidy
35+ run : |
36+ go mod tidy
37+ git diff --exit-code
38+
39+ - name : Run coverage
40+ run : go tool gotestsum --format github-actions --junitfile junit.xml -- -coverprofile=coverage.out -covermode=count ./...
41+
42+ - name : Upload coverage to Codecov
43+ uses : codecov/codecov-action@v5
44+
45+ - name : Upload test results to Codecov
46+ if : ${{ !cancelled() }}
47+ uses : codecov/test-results-action@v1
48+ with :
49+ token : ${{ secrets.CODECOV_TOKEN }}
You can’t perform that action at this time.
0 commit comments