In March 2023, HashiCorp released Terraform 1.4 with improvements to testing infrastructure and the checks feature. This update is part of a larger story about the infrastructure-as-code landscape as Terraform strengthens its position.

Terraform 1.4 introduces native test infrastructure with test files and a terraform test command. Before, testing Terraform configurations required third-party tools like Terratest or kitchen-terraform. Now, you can write assertions about your infrastructure in HCL, Terraform's configuration language, without adding a separate testing framework. The current capability is basic, but it's a step in the right direction for infrastructure-as-code testing.

The new testing model in Terraform 1.4 struggles with complex assertions that require external validation, like verifying IAM policies or checking cross-account S3 bucket permissions. For example, ensuring a DynamoDB table's encryption key is correctly referenced across multiple regions still requires Terratest or custom scripts. Teams adopting Terraform 1.4's tests often find themselves writing 20-30% more boilerplate HCL to simulate production scenarios that would be simpler in a full programming language.

Pulumi offers an alternative to Terraform by letting you define infrastructure in languages like TypeScript, Python, Go, or C#. For teams with strong programming language expertise, Pulumi's type system, IDE support, and ability to use standard testing frameworks for infrastructure tests are significant advantages over HCL. However, this comes with a smaller ecosystem and less community documentation. Pulumi has grown notably in 2022 and 2023, but Terraform's ecosystem advantage is substantial.

In a 2023 case study, a fintech company using Pulumi with Python reduced infrastructure misconfigurations by 40% during CI/CD by leveraging Pytest for unit testing. However, their onboarding time doubled compared to teams using Terraform’s HCL, and debugging state convergence issues in large clusters took 50% longer due to the lack of mature tooling for state reconciliation in Pulumi.

In August 2023, HashiCorp changed Terraform's license from open source to Business Source License. This change prevents using Terraform to build competing managed services. In response, the OpenTofu project, a fork of Terraform under the Linux Foundation, was created. For organizations using Terraform with cloud providers' native backends, like AWS, Azure, or GCP state storage, the license change has no immediate impact. However, it does affect competitors to Terraform Cloud.

The Business Source License change has already caused friction in the DevOps community. For instance, HashiCorp explicitly prohibits using Terraform in projects like Terraform Cloud alternatives or managed Terraform-as-a-Service offerings. While OpenTofu aims to fill this gap, it lacks production-proven state management features like remote state locking for multi-tenant environments, which Terraform 1.4 introduced in 2023 with improved state consistency guarantees.

For Azure-only infrastructure, Azure Bicep is a compelling alternative to Terraform. It offers first-class Azure provider support, ARM template output, and native integration with the Azure CLI and Azure DevOps. For multi-cloud infrastructure or teams that want a single IaC tool across cloud providers, Terraform remains the standard. The decision comes down to architectural choices: single-cloud discipline versus multi-cloud flexibility.