go-testing-assertion-author

Write and refactor Go tests using house testing libraries and best practices.

1|Updated Feb 9, 2026
One-click install
npx skills add https://github.com/mikeschinkel/ai-agent-depot --skill go-testing-assertion-author
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: go-testing-assertion-author
Source: https://github.com/mikeschinkel/ai-agent-depot/tree/main/skills/go-testing-assertion-author
Command: npx skills add https://github.com/mikeschinkel/ai-agent-depot --skill go-testing-assertion-author

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill helps Go developers write and refactor tests following Mike's testing best practices and house testing libraries (go-testutil, go-jsontest, go-fsfix, go-pipefunc) to improve reliability and readability.

Core Features & Use Cases

  • Guidelines for testing patterns, fixtures, golden data, and test helpers
  • Clear rules for table-driven tests and stable assertions
  • Use cases: authoring new tests, refactoring brittle tests, and improving diagnostics

Quick Start

Provide a complete, compilable test file for your Go package using the recommended patterns.

Frequently Asked Questions about go-testing-assertion-author

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I refactor brittle Go tests to use better assertions and fixtures?▼

Structure Go golden tests by organizing golden data across packages and applying clear diagnostic outputs. This skill supports golden test patterns alongside go-fsfix and go-pipefunc to ensure stable, readable test assertions.

What is the best way to structure table-driven tests in Go packages?▼

Structure table-driven tests in Go by following clear rules for stable assertions and test helpers. This skill provides guidelines for organizing table-driven patterns and fixtures to improve diagnostic outputs across packages.

Can I use go-testutil and go-jsontest for writing new Go tests?▼

Yes, you can use go-testutil and go-jsontest for writing new Go tests. This skill applies these house testing libraries to create complete, compilable test files using recommended patterns for assertions and fixtures.

When do I need golden data in Go testing, and how do I manage it?▼

You need golden data in Go testing when verifying complex outputs against expected results. This skill helps manage golden data across Go packages using go-fsfix and clear diagnostic outputs for stable assertions.

Why do my Go test assertions fail when refactoring, and how can I fix them?▼

Go test assertions often fail during refactoring due to brittle test structures. This skill helps fix them by applying testing best practices, clear assertion rules, and house libraries like go-testutil to improve reliability.