Skip to main content
skill CX Codex

run-acceptance-tests — Claude Code skill

Runs and investigates Terraform provider acceptance tests with the TestAcc prefix. Use it for missing environment variables, failed runs, or tests that pass when they should not.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add hashicorp/agent-skills --skill run-acceptance-tests -a claude-code
Open on GitHub

What run-acceptance-tests does

This skill guides Go acceptance-test runs for Terraform providers when the test name starts with TestAcc. It uses TF_ACC=1, requires an explicit -timeout, and starts with normal test output. For a repeat investigation, it can add -count=1, then -v, TF_LOG=debug, and TF_ACC_WORKING_DIR_PERSIST=1.

It traces required environment variables through PreCheck or testAccPreCheck, searches for os.Getenv in *_test.go files, and checks README, CONTRIBUTING, or .env.example. The provider Configure method can also show the credential resolution chain. Secrets stay in a single command invocation rather than repository files.

These tests create real resources through the provider's live API and can incur costs. Check that credentials point to a test account before running them. The skill also explains how to flip a passing test by changing a test check, and suggests provider sweepers after an interrupted run.

What it helps with

  • run one TestAcc test with an explicit timeout
  • locate missing test environment variables
  • rerun a failed test without Go cache
  • turn on Terraform debug logging
  • check whether a passing test is a false negative

Example prompts for the agent

  • Run TestAccFeatureHappyPath as an acceptance test with TF_ACC=1 and an explicit timeout.
  • Find the environment variables required by this failing TestAcc test in PreCheck and *_test.go files.
  • Flip TestAccFeatureHappyPath to verify that its checks can fail.

How to install run-acceptance-tests

1Skills CLI (Vercel)

npx skills add hashicorp/agent-skills --skill run-acceptance-tests -a claude-code

2Manually: put the files in place

~/.claude/skills/run-acceptance-tests/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/run-acceptance-tests/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about run-acceptance-tests

How do I install run-acceptance-tests in Claude Code?

Run npx skills add hashicorp/agent-skills --skill run-acceptance-tests -a claude-code, then run npx skills add hashicorp/agent-skills --skill run-acceptance-tests -a claude-code again. The skill file is placed at ~/.claude/skills/run-acceptance-tests/SKILL.md.

What does run-acceptance-tests do?

It guides Terraform provider acceptance-test execution and failure investigation. It covers environment setup, cache bypassing, verbose output, debug logs, workspace persistence, and false-negative checks.

Why should credentials point to a test account?

Acceptance tests call the provider's live API and create real infrastructure. That can incur costs when the configured credentials target a non-test account.

Similar skills

Everything for Testing and QA →

From the same set16

terraform-search-import Discovers untracked cloud assets and sets up Terraform configuration for bulk state imports. Helpful during infrastructure migrations and audits. CX Codex +1 4,900installs provider-resources This skill guides Terraform resource and data source work with the Plugin Framework. Use it when adding resources, handling drift, or reviewing provider code. CX Codex +1 4,100installs provider-actions Guides implementation of Terraform Actions with the Plugin Framework for operations run around resource create, update, and destroy events. CX Codex +1 3,900installs new-terraform-provider A skill that walks the agent through bootstrapping a Terraform provider on the Plugin Framework, from directory layout to a passing build. CX Codex +1 3,900installs provider-test-patterns A skill that guides acceptance testing for Terraform providers using terraform-plugin-testing and the Plugin Framework. CX Codex +1 3,300installs azure-verified-modules A skill that carries the Azure Verified Modules requirements, so your agent can write and review Terraform modules that pass AVM certification. CX Codex +1 3,300installs aws-ami-builder A skill that walks your agent through building Amazon Machine Images with Packer and the amazon-ebs builder — template, source AMI filters, build commands. CX Codex +1 3,200installs provider-docs Guides Terraform provider documentation workflows for the Terraform Registry. It coordinates schema descriptions, docs templates, and tfplugindocs generation. CX Codex +1 3,200installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor