-
Notifications
You must be signed in to change notification settings - Fork 3
63 lines (53 loc) · 1.7 KB
/
coverage.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Coverage
on: [push, pull_request]
jobs:
codecov:
name: codecov
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Load .env file
uses: cardinalby/export-env-action@v2
with:
envFile: .env
- uses: actions/setup-go@v3
with:
go-version: 1.22.6
- name: Generate coverage report (multi-auth)
run: |
cd plugins/multi-auth
go mod tidy
go test -race ./... -coverprofile=coverage-multi-auth-plugin.txt -covermode=atomic
- name: Generate coverage report (grpc-proxy)
run: |
cd plugins/grpc-proxy
go mod tidy
go test -race ./... -coverprofile=coverage-grpc-proxy-plugin.txt -covermode=atomic
- name: Generate coverage report (registry)
run: |
cd plugins/registry
go mod tidy
go test -race ./... -coverprofile=coverage-registry-plugin.txt -covermode=atomic
- name: Upload coverage report (multi-auth)
uses: codecov/codecov-action@v2
with:
file: ./coverage-multi-auth-plugin.txt
flags: unittests
name: codecov-umbrella
- name: Upload coverage report (grpc-proxy)
uses: codecov/codecov-action@v2
with:
file: ./coverage-grpc-proxy-plugin.txt
flags: unittests
name: codecov-umbrella
- name: Upload coverage report (registry)
uses: codecov/codecov-action@v2
with:
file: ./coverage-registry-plugin.txt
flags: unittests
name: codecov-umbrella