Makefile: Split out coverage into a shell script

This commit is contained in:
Alexander Neumann
2015-05-10 23:04:02 +02:00
parent be8064cd97
commit b7e1d2788b
2 changed files with 11 additions and 5 deletions
+10
View File
@@ -0,0 +1,10 @@
#!/bin/bash
TARGETFILE="$1"
go list ./... | while read pkg; do
go test -covermode=count -coverprofile=$(base64 <<< $pkg).cov $pkg
done
echo "mode: count" > $TARGETFILE
tail -q -n +2 *.cov >> $TARGETFILE