-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
39 lines (31 loc) · 1015 Bytes
/
Copy pathMakefile
File metadata and controls
39 lines (31 loc) · 1015 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
export TEST_TIMEOUT_IN_SECONDS := 240
export PKG := github.com/ynori7/trytryagain
export ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
install:
go install -v $(PKG)/...
.PHONY: install
install-dependencies:
go get -t -v $(PKG)/...
go test -i -v $(PKG)/...
.PHONY: install-dependencies
install-tools:
# linting
go get -u -v golang.org/x/lint/golint/...
# code coverage
go get -u -v golang.org/x/tools/cmd/cover
go get -u -v github.com/onsi/ginkgo/ginkgo/...
go get -u -v github.com/modocache/gover/...
go get -u -v github.com/mattn/goveralls/...
.PHONY: install-tools
lint:
$(ROOT_DIR)/scripts/lint.sh
.PHONY: lint
test:
go test -race -test.timeout "$(TEST_TIMEOUT_IN_SECONDS)s" ./...
.PHONY: test
test-verbose:
go test -race -test.timeout "$(TEST_TIMEOUT_IN_SECONDS)s" -v ./...
.PHONY: test-verbose
test-verbose-with-coverage:
go test -race -coverprofile workerpool.coverprofile -test.timeout "$(TEST_TIMEOUT_IN_SECONDS)s" -v ./...
.PHONY: test-verbose-with-coverage