-
Notifications
You must be signed in to change notification settings - Fork 2
39 lines (36 loc) · 1.38 KB
/
collect-coverage.yml
File metadata and controls
39 lines (36 loc) · 1.38 KB
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
name: Collect coverage
permissions:
pull-requests: read
contents: read
on:
workflow_call:
jobs:
collect-coverage:
# description: |
# Gather, merge then uploads test coverage files from all test jobs (this includes integration tests,
# like codegen-test). This reduces the number of failures due to codecov hitting github API rate limit.
name: collect test coverage
runs-on: ubuntu-latest
steps:
-
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}
-
name: Download coverage artifacts
uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0
with:
run-id: "${{ github.run_id }}"
pattern: "*.coverage.*"
# artifacts resolve as folders
path: coverage/
-
name: Upload coverage to codecov
uses: codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
with:
name: Aggregated coverage
# All *.coverage.*.out files uploaded should be detected by the codecov action.
# NOTE: we lose the flags on individual test reports (e.g. by os, by go version, unit vs integration tests)
fail_ci_if_error: false
verbose: false