What problem does it solve?
This Skill solves the problem of fragile or incomplete Laravel test coverage by guiding a disciplined test-driven workflow that keeps unit, feature, and integration tests green.
Core Features & Use Cases
- Test-driven development workflow: Use the red-green-refactor cycle to write failing tests first, implement minimal changes, then refactor safely.
- Correct test layering: Choose the right test type—unit for pure logic, feature for HTTP/auth/validation/policies, integration when multiple boundaries (DB/queues/externals) must work together.
- Reliable database testing: Default to RefreshDatabase for most DB tests, and switch to DatabaseTransactions or DatabaseMigrations when the schema or rollback strategy requires it.
- Deterministic side-effect testing: Use fakes for queues, mail, notifications, events, buses, and HTTP calls to isolate external dependencies.
- Coverage-first guidance: Target 80%+ coverage for unit + feature tests and run via phpunit/pest in CI with coverage tooling.
Quick Start
Tell the AI to create a failing Pest feature test for a new Laravel endpoint, then outline the minimal implementation and database assertions needed to make it pass with RefreshDatabase.