Clone repository locally and run
mise install
mise run buildRun mise install to install the pinned versions of Go, Terraform, GoReleaser, and the development tools.
To compile the provider, run mise run build. GoReleaser writes the provider binary beneath dist/.
mise run buildOn macOS and Linux, test a local provider build through the terraform mise task. It builds the provider and creates a temporary CLI configuration containing the development override, leaving your ~/.terraformrc unchanged.
mise run terraform -- planTo use a Terraform configuration outside this repository, pass its directory with -chdir:
mise run terraform -- -chdir=/path/to/config plan
mise run terraform -- -chdir=/path/to/config apply- HashiCorp - Development Overrides for Provider developers.
Run the unit tests without creating Vercel resources:
mise run test:unitRun the acceptance tests with:
Note
This runs acceptance tests that will create real resources. You should expect that the full acceptance test suite will take some time to run.
The acceptance tests require a few environment variables to be set:
VERCEL_API_TOKEN- this can be generated at vercel.com/account/tokensVERCEL_TERRAFORM_TESTING_TEAM- a Vercel team_id where resources can be created and destroyedVERCEL_TERRAFORM_TESTING_GITHUB_REPO- a GitHub repository in the form 'org/repo' that can be used to trigger deploymentsVERCEL_TERRAFORM_TESTING_BITBUCKET_REPO- a Bitbucket repository in the form 'project/repo' that can be used to trigger deploymentsVERCEL_TERRAFORM_TESTING_GITLAB_REPO- a GitLab repository in the form 'project/repo' that can be used to trigger deploymentsVERCEL_TERRAFORM_TESTING_DOMAIN- a Vercel testing domain that can be used for testingVERCEL_TERRAFORM_TESTING_EXISTING_INTEGRATION- a Vercel integration that can be used for testing
mise run test:acceptanceIn order to run the tests with extra debugging context, prefix with TF_LOG (see the terraform documentation for details).
TF_LOG=INFO mise run test:acceptanceTo run a specific set of tests, use the -run flag and specify a regex pattern matching the test names.
mise run test:acceptance -run 'TestAcc_Project*'mise run docsThe documentation is autogenerated from Description fields within the provider, and the examples directory.
Building the documentation generates markdown in the docs folder, ready for deployment to Hashicorp.
-
To view the documentation:
Paste
/docsMarkdown file content into https://registry.terraform.io/tools/doc-preview