Merge pull request #1198 from weaveworks/1146-coverage

When running unit tests, output coverage for imported modules.
This commit is contained in:
Tom Wilkie committed 2015-07-20 20:34:12 +01:00
commit 4c9b0be117
1 file changed
+2 -1
+2 -1
View File
@@ -32,8 +32,9 @@ for dir in $TESTDIRS; do
GO_TEST_ARGS_RUN="$GO_TEST_ARGS"
if [ -n "$SLOW" ]; then
COVERPKGS=$(go list -f '{{join .Deps "\n"}}' $dir | grep "weaveworks" | paste -s -d,)
output=$(mktemp $coverdir/unit.XXXXXXXXXX)
GO_TEST_ARGS_RUN="$GO_TEST_ARGS -coverprofile=$output"
GO_TEST_ARGS_RUN="$GO_TEST_ARGS -coverprofile=$output -coverpkg=$COVERPKGS"
fi
START=$(date +%s)