unverified()->create(); $this->actingAs($user) ->post(route('verification.send')) ->assertRedirect(route('home')); Notification::assertSentTo($user, VerifyEmail::class); } public function test_does_not_send_verification_notification_if_email_is_verified(): void { Notification::fake(); $user = User::factory()->create(); $this->actingAs($user) ->post(route('verification.send')) ->assertRedirect(route('dashboard', absolute: false)); Notification::assertNothingSent(); } }