Skip to content

Commit 266aa0f

Browse files
Fix test users_can_not_authenticate_with_invalid_password (#64)
* Update AuthenticationTest.php * Update AuthenticationTest.php --------- Co-authored-by: Taylor Otwell <[email protected]>
1 parent ace1927 commit 266aa0f

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

tests/Feature/Auth/AuthenticationTest.php

+6-4
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,12 @@ public function test_users_can_not_authenticate_with_invalid_password(): void
3838
{
3939
$user = User::factory()->create();
4040

41-
$this->post('/login', [
42-
'email' => $user->email,
43-
'password' => 'wrong-password',
44-
]);
41+
$response = LivewireVolt::test('auth.login')
42+
->set('email', $user->email)
43+
->set('password', 'wrong-password')
44+
->call('login');
45+
46+
$response->assertHasErrors('email');
4547

4648
$this->assertGuest();
4749
}

0 commit comments

Comments
 (0)