run metalinter in make test and run_test.sh
This commit is contained in:
parent
2e76b23c9a
commit
d9c87a21a6
9
Makefile
9
Makefile
|
@ -26,6 +26,8 @@ dist:
|
|||
@BUILD_TAGS='$(BUILD_TAGS)' sh -c "'$(CURDIR)/scripts/dist.sh'"
|
||||
|
||||
test:
|
||||
@echo "--> Running linter"
|
||||
@make metalinter_test
|
||||
@echo "--> Running go test"
|
||||
@go test $(PACKAGES)
|
||||
|
||||
|
@ -77,15 +79,14 @@ tools:
|
|||
|
||||
ensure_tools:
|
||||
go get $(GOTOOLS)
|
||||
@gometalinter --install
|
||||
|
||||
### Formatting, linting, and vetting
|
||||
|
||||
metalinter: ensure_tools
|
||||
@gometalinter --install
|
||||
metalinter:
|
||||
@gometalinter --vendor --deadline=600s --enable-all --disable=lll ./...
|
||||
|
||||
metalinter_test: ensure_tools
|
||||
@gometalinter --install
|
||||
metalinter_test:
|
||||
@gometalinter --vendor --deadline=600s --disable-all \
|
||||
--enable=deadcode \
|
||||
--enable=gas \
|
||||
|
|
|
@ -24,7 +24,6 @@ dependencies:
|
|||
|
||||
test:
|
||||
override:
|
||||
- cd "$PROJECT_PATH" && make get_vendor_deps && make metalinter_test
|
||||
- cd "$PROJECT_PATH" && set -o pipefail && make test_integrations 2>&1 | tee test_integrations.log:
|
||||
timeout: 1800
|
||||
post:
|
||||
|
|
|
@ -6,6 +6,10 @@ pwd
|
|||
BRANCH=$(git rev-parse --abbrev-ref HEAD)
|
||||
echo "Current branch: $BRANCH"
|
||||
|
||||
# run the linter
|
||||
# TODO: drop the `_test` once we're ballin' enough
|
||||
make metalinter_test
|
||||
|
||||
# run the go unit tests with coverage
|
||||
bash test/test_cover.sh
|
||||
|
||||
|
|
Loading…
Reference in New Issue