Skip to content

Commit

Permalink
travis : coverage.sh need to set the tag test
Browse files Browse the repository at this point in the history
Change-Id: Ief7bbc63235ee269640901cb84566b674486bab4
Signed-off-by: Nicolas PLANEL <nplanel@redhat.com>
Reviewed-on: https://softwarefactory-project.io/r/6242
Reviewed-by: Sylvain Afchain <safchain@gmail.com>
Tested-by: Sylvain Afchain <safchain@gmail.com>
Workflow: Sylvain Afchain <safchain@gmail.com>
Tested-by: Jenkins CI <jenkins@softwarefactory-project.io>
  • Loading branch information
nplanel authored and Jenkins CI committed Jan 27, 2017
1 parent be070ba commit 4612ff2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions coverage.sh
Expand Up @@ -24,13 +24,13 @@ generate_cover_data() {
PKG=$(go list ./... | grep -v -e '/tests' -e '/vendor')
for pkg in ${PKG}; do
coverfile="$workdir/$(echo $pkg | tr / -).cover"
govendor test -timeout 6m -covermode="$mode" -coverprofile="$coverfile" "$pkg"
govendor test -tags "${TAGS} test" -timeout 6m -covermode="$mode" -coverprofile="$coverfile" "$pkg"
done

# add fonctional testing
PKG=$(go list ./... | grep -v -e '/tests' -e '/vendor' | tr '\n' ',' | sed -e 's/,$//')
coverfile="$workdir/functional.cover"
govendor test -v -cover -covermode="$mode" -coverprofile="$f" -coverpkg=${PKG} -timeout 2m -c -o tests/functionals ./tests/
govendor test -tags "${TAGS} test" -v -cover -covermode="$mode" -coverprofile="$f" -coverpkg=${PKG} -timeout 2m -c -o tests/functionals ./tests/
FUNC_TESTS=$( grep -e 'func Test' tests/*.go | perl -pe 's|.*func (.*?)\(.*|\1|g' | shuf )
for functest in ${FUNC_TESTS} ; do
coverfile="../$workdir/$functest.cover"
Expand Down

0 comments on commit 4612ff2

Please sign in to comment.