How do I re-run all module tests after updating Terraform version?

Last updated: August 6, 2025

How do I re-run all module tests after updating Terraform version?

Context

When updating the Terraform version in your environment, you may want to verify that all existing modules continue to work correctly by re-running all module tests with the new version.

Answer

Currently, the only way to trigger new test runs for modules is to push a new version of the module. To re-run all module tests with a new Terraform version:

  1. Update the terraform_version value in your module to specify the new version

  2. Create and push a new version of your module

Note that you can create a new version even without making any other changes to the module code - the version update alone will trigger the test runs. Tests will run automatically when the new version is pushed.