2020-03-01 19:59:19 +00:00
|
|
|
.PHONY: help deps fmt lint test test-race test-integration
|
|
|
|
|
|
|
|
help:
|
|
|
|
@echo ""
|
|
|
|
@echo "Welcome to slack-go/slack make."
|
|
|
|
@echo "The following commands are available:"
|
|
|
|
@echo ""
|
|
|
|
@echo " make deps : Fetch all dependencies"
|
|
|
|
@echo " make fmt : Run go fmt to fix any formatting issues"
|
|
|
|
@echo " make lint : Use go vet to check for linting issues"
|
|
|
|
@echo " make test : Run all short tests"
|
|
|
|
@echo " make test-race : Run all tests with race condition checking"
|
|
|
|
@echo " make test-integration : Run all tests without limiting to short"
|
|
|
|
@echo ""
|
|
|
|
@echo " make pr-prep : Run this before making a PR to run fmt, lint and tests"
|
|
|
|
@echo ""
|
|
|
|
|
|
|
|
deps:
|
|
|
|
@go mod tidy
|
|
|
|
|
|
|
|
fmt:
|
|
|
|
@go fmt .
|
|
|
|
|
|
|
|
lint:
|
|
|
|
@go vet .
|
|
|
|
|
|
|
|
test:
|
2020-03-28 22:50:47 +00:00
|
|
|
@go test -v -count=1 -timeout 300s -short ./...
|
2020-03-01 19:59:19 +00:00
|
|
|
|
|
|
|
test-race:
|
2020-03-28 22:50:47 +00:00
|
|
|
@go test -v -count=1 -timeout 300s -short -race ./...
|
2020-03-01 19:59:19 +00:00
|
|
|
|
|
|
|
test-integration:
|
2020-03-28 22:50:47 +00:00
|
|
|
@go test -v -count=1 -timeout 600s ./...
|
2020-03-01 19:59:19 +00:00
|
|
|
|
|
|
|
pr-prep: fmt lint test-race test-integration
|