pest-package-tests
Installation
SKILL.md
Pest Tests for Framework-Agnostic Packages
Use this skill for standalone Composer packages that do not boot Laravel. There is no service container, no Laravel fakes, and no Eloquent. Resolve collaborators with new, build test data with fbarrento/data-factory for data objects, and roll in-memory doubles for service dependencies.
When testing inside a full Laravel application instead, prefer the laravel-rules skill.
Quick Start
use FBarrento\DataFactory\Factory;
use Vendor\Package\Actions\CreateWaitlistSignup;
use Vendor\Package\Data\CreateWaitlistSignupData;
beforeEach(function (): void {
$this->createWaitlistSignup = new CreateWaitlistSignup();
});