Advertisement
gempir

Untitled

Mar 10th, 2017
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Make 0.38 KB | None | 0 0
  1. PACKAGES = $(shell find ./ -type d -not -path '*/\.*')
  2.  
  3. build:
  4.     go build
  5.  
  6. install:
  7.     go install
  8.  
  9. test:
  10.     go test $(go list ./... | grep -v /vendor/)
  11.  
  12. cover:
  13.     echo "mode: count" > coverage-all.out
  14.     $(foreach pkg,$(PACKAGES),\
  15.         go test -coverprofile=coverage.out -covermode=count $(pkg);\
  16.         tail -n +2 coverage.out >> coverage-all.out;)
  17.     go tool cover -html=coverage-all.out
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement