Skip to content
T

terraform-test

Comprehensive guide for writing and running Terraform tests

by hashicorpFree

#5342in AI Skills
0In stores

Description

terraform-test is an agent skill that guides the writing and running of Terraform tests. It covers Terraform's built-in testing framework, w…

Highlights

  • Guides Terraform test files, run blocks and assertions
  • Explains plan and apply test modes
  • Mock providers for Terraform 1.7.0 and later
  • CI examples for GitHub Actions and GitLab

Ratings & Reviews

No ratings yet

Be the first to rate terraform-test.

People also visit

H

hashicorp/terraform-test

Built-in testing framework for Terraform configurations with .tftest.hcl files

AI Skills
Get
H

hashicorp/provider-test-patterns

Acceptance test patterns for Terraform providers using terraform-plugin-testing

AI Skills
Get
R

run-acceptance-tests

Guide for running acceptance tests for a Terraform provider

AI Skills
Get
H

hashicorp/run-acceptance-tests

Run acceptance tests for Terraform providers using Go's test runner

AI Skills
Get
P

provider-test-patterns

Terraform provider acceptance test patterns using terraform-plugin-testing

AI Skills
Get
T

terraform-skill

by Anton Babenko

AI Skills
Get

terraform-test FAQ

What does the terraform-test skill do?

It helps an agent write and run Terraform tests, with run blocks, assertions, mock providers and CI pipeline examples.

How do I install it?

Run npx skills add https://github.com/hashicorp/agent-skills --skill terraform-test in your project.

Do the tests create real resources?

Tests run in apply mode by default, which creates real resources, or in plan mode, which only validates logic. Tests run against temporary resources, so existing infrastructure is protected.

Which Terraform versions do mocks need?

Mock providers need Terraform 1.7.0 or later, and the skill says to skip them for older versions.

Does it include CI examples?

Yes. Reference files show GitHub Actions and GitLab CI pipelines for running the tests.

What are the security audit results?

Gen Agent Trust Hub: Pass. Socket: Pass. Snyk: Pass.

What are the best terraform-test alternatives?

Popular alternatives to terraform-test include hashicorp/terraform-test, hashicorp/provider-test-patterns and run-acceptance-tests. See all terraform-test alternatives

Developer Stuff

Badges