Back to skills
SKILL.md
Testing
ASecurityGo testing patterns. Routes to specific patterns.
- 3 stars
- 0 votes
- 0 copies
- 0 views
- Added February 7, 2026
Security analysis
100/100Pro scans all 5 files and shows the line behind each finding
npx -y skills add JamesPrial/claudefiles --skill testing --agent claude-codeAre you the author of Testing?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/jamesprial-testing)---
name: go-testing
description: Go testing patterns. Routes to specific patterns.
---
# Testing
## Route by Pattern
- Table-driven tests → see [table/](table/)
- Subtests with t.Run → see [subtests/](subtests/)
- Test helpers → see [helpers/](helpers/)
- Benchmarks → see [benchmarks/](benchmarks/)
## Quick Check
- [ ] Tests named Test_Function_Scenario
- [ ] Table tests for >2 cases
- [ ] Helpers call t.Helper()
- [ ] Parallel tests capture loop vars
## Common Patterns
**Basic test structure:**
```go
func Test_Function_Scenario(t *testing.T) {
// Arrange
input := "test"
// Act
result := Function(input)
// Assert
if result != expected {
t.Errorf("got %v, want %v", result, expected)
}
}
```
Files in this skill
- SKILL.md
- benchmarks/SKILL.md
- helpers/SKILL.md
- subtests/SKILL.md
- table/SKILL.md
Attribution
Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.