blob: 3344ed81e53c7ae54e062bcadc080d9d55cec22e [file] [log] [blame]
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07001@echo off
2rem Coverage report for windows builds
3rem
4rem First general build
5echo Building the source
6go build
7if ERRORLEVEL 1 GOTO buildFaild
8
9echo Starting unit test coverage
10go test . examples/... generated/... -coverprofile=cp.out
11
12rem Output HTML coverage report (to coverage.html)
13echo Creating HTML coverage report (coverage.html)
14go tool cover -html=cp.out
15
16rem Now show in default browser
17echo Launching browser with results
18rem start coverage.html
19
20@echo Done
21exit /B 0
22
23:buildFailed
24@echo Build failed