build: Exclude .glide from test coverage.

The most recent version of glide creates a working directory named
.glide that includes .go files and thus must be excluded from the find
operation that generates merged test coverage of all packages.
This commit is contained in:
Dave Collins 2017-01-23 11:39:25 -06:00
parent c2af640c95
commit 28d42ba23c
No known key found for this signature in database
GPG key ID: B8904D9D9C93D1F2

View file

@ -46,8 +46,8 @@ echo "mode: count" > profile.cov
# Standard go tooling behavior is to ignore dirs with leading underscores.
for dir in $(find . -maxdepth 10 -not -path '.' -not -path './.git*' \
-not -path '*/_*' -not -path './cmd*' -not -path './release*' \
-not -path './vendor*' -type d)
-not -path './.glide*' -not -path '*/_*' -not -path './cmd*' \
-not -path './release*' -not -path './vendor*' -type d)
do
if ls $dir/*.go &> /dev/null; then
go test -covermode=count -coverprofile=$dir/profile.tmp $dir