blob: 6cad29f2c17f8d4f0b6d0abcb102e9d54e3447a9 [file] [log] [blame]
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07001default: services test
2
3.PHONY: test
4test:
5 go test ./...
6
7.PHONY: cover
8cover:
9 go list -f '{{if len .TestGoFiles}}"go test -coverprofile={{.Dir}}/.coverprofile {{.ImportPath}}"{{end}}' ./... | xargs -L 1 sh -c
10
11.PHONY: publish_cover
12publish_cover: cover
13 go get -d golang.org/x/tools/cmd/cover
14 go get github.com/modocache/gover
15 go get github.com/mattn/goveralls
16 gover
17 @goveralls -coverprofile=gover.coverprofile -service=travis-ci -repotoken=$(COVERALLS_TOKEN)
18
19.PHONY: clean
20clean:
21 @find . -name \.coverprofile -type f -delete
22 @rm -f gover.coverprofile