lernschiff/tests/Feature/DevQuickLogin/QuickLoginRendersTest.php

22 lines
623 B
PHP

<?php
use function Pest\Laravel\get;
uses(\Illuminate\Foundation\Testing\RefreshDatabase::class);
beforeEach(function () {
// Register the dev route for these tests, simulating local env with ALLOW_QUICK_LOGIN
\Illuminate\Support\Facades\Route::get(
'/dev/quick-login',
\App\Livewire\DevQuickLogin::class
)->name('dev.quick-login.test');
});
it('quick-login page renders for unauthenticated user without 500 error', function () {
get('/dev/quick-login')->assertOk();
});
it('quick-login page shows user buttons', function () {
get('/dev/quick-login')->assertSee('Quick Login');
});