Merge pull request #7526 from memsql/make-test-if-vendored

Makefile: Support `make test` if Terraform itself is vendored
This commit is contained in:
James Nugent 2016-07-08 11:42:37 +01:00 committed by GitHub
commit 6eba38dbb3
1 changed files with 4 additions and 3 deletions

View File

@ -1,4 +1,4 @@
TEST?=$$(go list ./... | grep -v '/vendor/' | grep -v '/builtin/bins/')
TEST?=$$(go list ./... | grep -v '/terraform/vendor/' | grep -v '/builtin/bins/')
VETARGS?=-all
GOFMT_FILES?=$$(find . -name '*.go' | grep -v vendor)
@ -29,7 +29,8 @@ core-dev: generate
# Shorthand for quickly testing the core of Terraform (i.e. "not providers")
core-test: generate
@echo "Testing core packages..." && go test -tags 'core' $(TESTARGS) $(shell go list ./... | grep -v -E 'builtin|vendor')
@echo "Testing core packages..." && \
go test -tags 'core' $(TESTARGS) $(shell go list ./... | grep -v -E 'terraform/(builtin|vendor)')
# Shorthand for building and installing just one plugin for local testing.
# Run as (for example): make plugin-dev PLUGIN=provider-aws
@ -79,7 +80,7 @@ generate:
@which stringer ; if [ $$? -ne 0 ]; then \
go get -u golang.org/x/tools/cmd/stringer; \
fi
go generate $$(go list ./... | grep -v /vendor/)
go generate $$(go list ./... | grep -v /terraform/vendor/)
@go fmt command/internal_plugin_list.go > /dev/null
fmt: