Skip to content

Commit

Permalink
Allow override for running tests
Browse files Browse the repository at this point in the history
  • Loading branch information
erikzaadi committed May 12, 2024
1 parent 82cd574 commit 1a9e547
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ VERSION=0.9.6
OS=$(shell go env GOOS)
ARCH=$(shell go env GOARCH)
OS_ARCH=${OS}_${ARCH}
TEST_FILTER?=.*

default: install

Expand Down Expand Up @@ -40,7 +41,8 @@ setup:
cd tools && go install github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs

acctest:
TF_ACC=1 PORT_CLIENT_ID=$(PORT_CLIENT_ID) PORT_CLIENT_SECRET=$(PORT_CLIENT_SECRET) PORT_BASE_URL=$(PORT_BASE_URL) go test -p 1 ./...
# TEST_FILTER can be any regex, E.g: .*PageResource.*
TF_ACC=1 PORT_CLIENT_ID=$(PORT_CLIENT_ID) PORT_CLIENT_SECRET=$(PORT_CLIENT_SECRET) PORT_BASE_URL=$(PORT_BASE_URL) go test -p 1 ./... -run "$(TEST_FILTER)"

gen-docs:
tfplugindocs

0 comments on commit 1a9e547

Please sign in to comment.