build: run end-to-end tests during Travis run
We don't usually run "acceptance tests" during a Travis run, but this particular suite doesn't require any special credentials since it just accesses releases.hashicorp.com to download plugins, so therefore it's safe to run in Travis at the expense of adding a few more seconds to the runtime. Running it in Travis can therefore give us some extra confidence for pull requests that may inadvertently break certain details of the workflow, as well as ensuring that these tests are kept up-to-date as the system changes.
This commit is contained in:
parent
73d1298572
commit
f45aae9b70
|
@ -27,6 +27,7 @@ install:
|
|||
script:
|
||||
- make vendor-status
|
||||
- make test
|
||||
- make e2etest
|
||||
- make vet
|
||||
- GOOS=windows go build
|
||||
branches:
|
||||
|
|
8
Makefile
8
Makefile
|
@ -42,6 +42,12 @@ testacc: fmtcheck generate
|
|||
fi
|
||||
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m
|
||||
|
||||
# e2etest runs the end-to-end tests against a generated Terraform binary
|
||||
# The TF_ACC here allows network access, but does not require any special
|
||||
# credentials since the e2etests use local-only providers such as "null".
|
||||
e2etest: generate
|
||||
TF_ACC=1 go test -v ./command/e2etest
|
||||
|
||||
test-compile: fmtcheck generate
|
||||
@if [ "$(TEST)" = "./..." ]; then \
|
||||
echo "ERROR: Set TEST to a specific package. For example,"; \
|
||||
|
@ -96,4 +102,4 @@ vendor-status:
|
|||
# under parallel conditions.
|
||||
.NOTPARALLEL:
|
||||
|
||||
.PHONY: bin cover default dev fmt fmtcheck generate plugin-dev quickdev test-compile test testacc testrace tools vendor-status vet
|
||||
.PHONY: bin cover default dev e2etest fmt fmtcheck generate plugin-dev quickdev test-compile test testacc testrace tools vendor-status vet
|
||||
|
|
Loading…
Reference in New Issue