github.com/Finschia/finschia-sdk@v0.48.1/contrib/test_cover.sh (about) 1 #!/usr/bin/env bash 2 set -e 3 4 PKGS=$(go list ./... | grep -v '/simapp') 5 6 set -e 7 echo "mode: atomic" > coverage.txt 8 for pkg in ${PKGS[@]}; do 9 go test -v -timeout 30m -race -coverprofile=profile.out -covermode=atomic -tags='ledger test_ledger_mock goleveldb' "$pkg" 10 if [ -f profile.out ]; then 11 tail -n +2 profile.out >> coverage.txt; 12 rm profile.out 13 fi 14 done