Role
This skill designs the data side of unit-level regression protection. It focuses on fixtures, edge-case input matrices, and deterministic reproduction data that makes logic regressions visible and maintainable.
When To Use
- Use for fixture design, data providers, edge-case matrices, and regression input preparation.
- Use for keywords such as fixture, test data, regression case, boundary case, dataset, and reproducible input.
- Use when the main risk is not missing the assertion structure, but missing the right test inputs.
Source Material
AI-ENTRY.mdCLAUDE.mddev/ai/skills/testing/SKILL.mddev/ai/skills/community-module/SKILLS-CONSOLIDATED.mddev/ai/skills/php84-performance/SKILL.md
Responsibilities
- Build stable and realistic test inputs for changed logic.
- Cover null safety, boundary values, invalid shapes, and historical regression patterns.
- Keep test data readable and close to the business rule being protected.
- Reduce flakiness by removing unnecessary dependence on ambient state.
Workflow
- Read the defect or feature behavior and identify the minimum input combinations that matter.
- Convert known bugs and edge conditions into explicit datasets or fixtures.
- Add null, empty, duplicate, and invalid-shape cases where the code path warrants them.
- Keep test data local, named, and understandable.
- Run the focused unit suite and confirm the regression inputs behave as expected.
- Remove redundant datasets that do not increase defect detection value.
- Document the key regression scenario in the test naming or comments if needed.
Weline Rules
- Prefer small, isolated, testable changes.
- Provide unit test evidence where relevant.
- Follow PHP null-safety expectations when building regression cases.
- Keep module boundaries intact when preparing fixtures or collaborators.
Inputs Required
- The changed logic and known failure modes.
- Historical bug symptoms, edge cases, or stack-trace triggers.
- Existing fixture style in the target module.
- Focused unit-test command for verification.
Expected Output
- Focused datasets or fixtures that reproduce meaningful edge cases.
- Updated regression coverage with clear input intent.
- Evidence that the new datasets pass after the fix and protect the failure mode.
Validation
- Run focused unit tests that consume the new datasets or fixtures.
- Confirm the added cases cover meaningful branches or prior bugs.
- Confirm no dataset depends on unrelated mutable global state.
- Confirm fixture complexity stays justified by risk.
Constraints
- Do not add bulky generic fixtures that hide the real regression case.
- Do not depend on random values or time-sensitive data without control.
- Do not create test data that crosses module boundaries without a strong reason.
- Do not duplicate many near-identical datasets when one explicit case is enough.