mirror of https://github.com/milvus-io/milvus.git
[skip ci] Add description to coverage script (#9138)
Signed-off-by: Yihua <michaelmo@YihuadeMacBook-Pro.local> Co-authored-by: Yihua <michaelmo@YihuadeMacBook-Pro.local>pull/9143/head
parent
9600407f83
commit
94af9ec47d
|
@ -6,6 +6,7 @@ FILE_COVERAGE_HTML="go_coverage.html"
|
|||
set -e
|
||||
echo "mode: atomic" > ${FILE_COVERAGE_INFO}
|
||||
|
||||
# run unittest
|
||||
for d in $(go list ./internal... | grep -v vendor); do
|
||||
go test -race -coverpkg=./... -coverprofile=profile.out -covermode=atomic "$d"
|
||||
if [ -f profile.out ]; then
|
||||
|
@ -14,5 +15,6 @@ for d in $(go list ./internal... | grep -v vendor); do
|
|||
fi
|
||||
done
|
||||
|
||||
# generate html report
|
||||
go tool cover -html=./${FILE_COVERAGE_INFO} -o ./${FILE_COVERAGE_HTML}
|
||||
echo "Export go coverage report to ${FILE_COVERAGE_HTML}"
|
||||
|
|
Loading…
Reference in New Issue