.github/skills/provider-build-test/SKILL.md
Regenerate Go code from resourceDefinition.json, build the terraform-provider-azurecaf binary, and run unit tests. Use after any change to resourceDefinition.json to verify the provider compiles and tests pass.
npx skillsauth add aztfmod/terraform-provider-azurecaf provider-build-testInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Run from the project root after editing resourceDefinition.json:
go generate # regenerates azurecaf/models_generated.go
make build # runs go generate + go fmt + go build + go test
Verify the resource appears in generated code:
grep "<resource_name>" azurecaf/models_generated.go
Expected output: ok for all test packages, coverage ~90%+, no compilation errors.
If go generate fails: check JSON formatting (missing commas, unmatched quotes, bad escapes).
If tests fail: check for duplicate slugs causing ambiguity.
development
Analyze test failure output to identify root cause and suggest fixes. Use when build or test failures occur. Triggers on: test failures, build errors, CI failures.
development
Validate a resource definition end-to-end using terraform test with mock_provider azurerm. Proves the CAF-generated name is accepted by the azurerm provider schema without Azure credentials. Use after provider-build-test succeeds to run the mocked azurerm integration test.
documentation
Analyze changes since the last release tag and determine the appropriate semantic version bump (patch/minor/major) based on CHANGELOG entries and commit types. Triggers on: release preparation, version planning.
testing
Compare two versions of resourceDefinition.json (e.g., branch vs main) and produce a structured change summary. Triggers on: PR review, audit, before/after comparison.