Files
Benjamin NussbaumandCursor f2ff4ad111 starter-kit-upgrade: Browser tests & Fortify skip guards
Upstream: laravel/livewire-starter-kit@0ca77fa
Adds skipUnlessFortifyHas on TestCase and Fortify-aware skips/assertions in auth tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-26 18:07:58 +02:00

17 lines
420 B
PHP

<?php
namespace Tests;
use Illuminate\Foundation\Testing\TestCase as BaseTestCase;
use Laravel\Fortify\Features;
abstract class TestCase extends BaseTestCase
{
protected function skipUnlessFortifyHas(string $feature, ?string $message = null): void
{
if (! Features::enabled($feature)) {
$this->markTestSkipped($message ?? "Fortify feature [{$feature}] is not enabled.");
}
}
}