File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -89,16 +89,18 @@ jobs:
8989 runs-on : ubuntu-latest
9090 needs : test-go-modules
9191 steps :
92- - uses : actions/download-artifact@v4
92+ - uses : actions/checkout@v3
93+ - name : Download coverage artifacts
94+ uses : actions/download-artifact@v4
9395 with :
9496 pattern : coverage-*
9597 merge-multiple : true
98+ path : coverage-artifacts
9699 - name : Combine coverage reports
97100 shell : bash
98101 run : |
99102 set -euo pipefail
100- shopt -s nullglob
101- files=(coverage-*.out)
103+ mapfile -t files < <(find coverage-artifacts -maxdepth 1 -type f -name 'coverage-*.out' | sort)
102104 if [ "${#files[@]}" -eq 0 ]; then
103105 echo "no coverage files found" >&2
104106 exit 1
@@ -107,6 +109,11 @@ jobs:
107109 for file in "${files[@]:1}"; do
108110 tail -n +2 "${file}" >> coverage.out
109111 done
112+ - name : Upload merged coverage artifact
113+ uses : actions/upload-artifact@v4
114+ with :
115+ name : coverage-merged
116+ path : coverage.out
110117 - name : Upload coverage reports to Codecov
111118 uses : codecov/codecov-action@v5
112119 with :
You can’t perform that action at this time.
0 commit comments