go-testing-quality
БесплатноБез исполняемых скриптовНе проверенUse when writing or reviewing Go tests, adding coverage, benchmarking, or profiling a Go program. Not for CI/lint wiring (go-tooling-security) or non-Go tests.
от Fusengine★ 36 звёзд на GitHubОб этом скилле
Go Testing & Quality
Idiomatic, 2026-current testing and quality practices for Go, built on the standard
testing package with testify where it adds clarity.
Use when:
- Writing unit tests for Go code (table-driven, subtests)
- Adding assertions or mocks with
testify(assert/require/mock) - Writing fuzz tests, benchmarks, or example tests
- Measuring coverage (
go test -cover) or chasing race conditions (-race) - Profiling / optimizing with pprof or setting up PGO
- Reviewing an existing Go test suite for quality gaps
Do NOT use for:
- Project layout, routing, DB wiring, DI — use
go-architecture - SOLID line-limit / interface enforcement — use
fuse-solid:solid-go - Non-Go test suites (Pest, Vitest, Jest, cargo test) — use the matching expert
- Security scanning / CVE audit — use
fuse-security
Decision Map
| Goal | Load |
|---|---|
| Write the standard Go test (table-driven + subtests) | table-driven.md |
| Assertions and mocks with testify | testify-mocks.md |
| Fuzzing, benchmarks, example tests | fuzzing-benchmarks.md |
| Coverage, race detector, pprof, PGO | coverage-profiling.md |
| A complete, runnable test file to copy | templates/table-test.md |
Core Practices (2026)
- Table-driven tests are the idiom. Define a slice of cases, loop, and run
each as a subtest with
t.Run(tc.name, …)for isolation and readable output. testifyis the de-facto assertion/mock standard.assertfor soft checks,requireto abort on failure,mockfor hand-written mocks,suitefor setup/teardown groups. It is maintained at v1 (no breaking v2). Source: https://pkg.go.dev/github.com/stretchr/testify- Fuzzing is native since Go 1.18 (
func FuzzXxx(f *testing.F)), and finds edge cases table tests miss. - Always run
-racein CI. The race detector catches data races that are otherwise nondeterministic and unreproducible. - Measure before optimizing. Benchmarks (
go test -bench) + pprof profiles guide real changes; PGO feeds a production profile back into the compiler.
Workflow
- Explore the code under test and existing test conventions first.
- Write table-driven tests as the default shape (table-driven.md).
- Add testify assertions/mocks where they improve readability, not reflexively.
- Run
go test ./... -race -coverand inspect gaps. - Fuzz / benchmark hotspots and parsers (fuzzing-benchmarks.md).
- Profile only after a benchmark proves a hotspot (coverage-profiling.md).
- Validate with sniper after changes.
Boundaries
Overlaps with github.com/samber/cc-skills-golang (community Go skills) — this
skill owns testing and quality tooling; architecture/structure lives in
go-architecture. Cross-referenced for boundaries only, not copied.
Установить go-testing-quality в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл go-testing-quality?
Use when writing or reviewing Go tests, adding coverage, benchmarking, or profiling a Go program. Not for CI/lint wiring (go-tooling-security) or non-Go tests.
Как установить скилл go-testing-quality?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл go-testing-quality запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
doc-coauthoring
Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
от Anthropicacademy-guide
Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
от Anthropicinternal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
от Anthropicskill-development
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…
от Anthropic