Skip to content

Commit 68fde98

Browse files
committed
feat(test): add per-func code coverage output to FV
Currently gotestsum just outputs the package-level metrics. For FV it would be useful to see the per-func metrics for the main package. Signed-off-by: Dominic Evans <[email protected]>
1 parent e5d4a45 commit 68fde98

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

.github/workflows/fvt.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ jobs:
5959
nohup sudo tcpdump -i lo -w "fvt-kafka-${{ inputs.kafka-version }}.pcap" portrange 29091-29095 >/dev/null 2>&1 &
6060
echo $! >tcpdump.pid
6161
make test_functional
62+
echo "## Code Coverage" >>$GITHUB_STEP_SUMMARY
63+
echo "|Filename|Function|Coverage|" >>$GITHUB_STEP_SUMMARY
64+
echo "|--------|--------|--------|" >>$GITHUB_STEP_SUMMARY
65+
go tool cover -func=profile.out | sed -E -e 's/[[:space:]]+/|/g' -e 's/$/|/g' -e 's/^/|/g' >>$GITHUB_STEP_SUMMARY
6266
- name: Stop tcpdump
6367
if: always()
6468
run: |

0 commit comments

Comments
 (0)