Mercurial > packages > auth
view stubs/default/pest-tests/Feature/Auth/PasswordConfirmationTest.php @ 2:ac199a7a8931 default tip
Changes to the views and only defualt option is available
| author | luka |
|---|---|
| date | Tue, 19 Aug 2025 20:32:36 -0400 |
| parents | 90e38de8f2ba |
| children |
line wrap: on
line source
<?php use App\Models\User; test('confirm password screen can be rendered', function () { $user = User::factory()->create(); $response = $this->actingAs($user)->get('/confirm-password'); $response->assertStatus(200); }); test('password can be confirmed', function () { $user = User::factory()->create(); $response = $this->actingAs($user)->post('/confirm-password', [ 'password' => 'password', ]); $response->assertRedirect(); $response->assertSessionHasNoErrors(); }); test('password is not confirmed with invalid password', function () { $user = User::factory()->create(); $response = $this->actingAs($user)->post('/confirm-password', [ 'password' => 'wrong-password', ]); $response->assertSessionHasErrors(); });
