baphled/dotopencode/test-fixtures
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Test data factory patterns
Install
npx vskill@latest install baphled/dotopencode/test-fixturesSKILL.md
Skill: test-fixtures
What I do
I provide expertise in consistent, realistic test data through factory patterns. I replace manual construction of complex test objects with factories that provide sensible defaults while allowing precise overrides for specific test scenarios.
When to use me
- Defining test data once and reusing it across entire test suites (DRY).
- Need valid, realistic objects without cluttering tests with irrelevant setup details.
- Isolating tests from changes in object internal structures (e.g. new mandatory fields).
- Managing complex object graphs and relationships in tests.
Core principles
- DRY Test Data — Define test objects once, reuse everywhere.
- Realistic Defaults — Use faker libraries for realistic, but random, data out of the box.
- Explicit Customisation — Override only what matters for the specific test case.
- Independence — Ensure each test gets fresh, non-shared objects to avoid leaks.
- Type Safety — Factories should return correctly typed objects or valid database records.
Patterns & examples
Factory Functions (Universal Pattern)
Traits and States (Ruby/FactoryBot)
Anti-patterns to avoid
- ❌ Hardcoded Constants — e.g. "test@test.com"; use random/realistic data to avoid accidental collisions.
- ❌ Manual Over-setup — Setting 10 fields in a test that only cares about one; use factory defaults.
- ❌ Shared Mutable Fixtures — Sharing the same object instance between tests; leads to flaky tests.
- ❌ Business Logic in Factories — Factories should only create data, not perform complex operations.
KB Reference
~/vaults/baphled/3. Resources/Knowledge Base/AI Development System/Skills/Testing-BDD/Test Fixtures.md
Related skills
test-fixtures-go- Go-specific factory-go/gofakeit implementation.bdd-workflow- Using fixtures effectively in the Red-Green-Refactor cycle.clean-code- Applying DRY and Single Responsibility to test data.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/test-fixtures/SKILL.md
Popularity
- Repository stars
- 1
- Repository forks
- 1
- 7-day trend score
- 8
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/baphled/dotopencode/test-fixtures)