Skip to content

A free open source IT asset/license management system

Fix assertion

Marcus Moore47f287c0312b
diff --git a/tests/Feature/Notifications/Email/EmailNotificationsUponCheckinTest.php b/tests/Feature/Notifications/Email/EmailNotificationsUponCheckinTest.php
index d46065da58..4497533f63 100644
--- a/tests/Feature/Notifications/Email/EmailNotificationsUponCheckinTest.php
+++ b/tests/Feature/Notifications/Email/EmailNotificationsUponCheckinTest.php
@@ -108,10 +108,12 @@ class EmailNotificationsUponCheckinTest extends TestCase
$user = User::factory()->create();
$asset = Asset::factory()->assignedToUser($user)->create();
+ $asset->model->category->update(['checkin_email' => true]);
+
$this->fireCheckInEvent($asset, $user);
- Mail::assertSent(CheckinAssetMail::class, function ($mail) use ($user) {
- return $mail->hasTo($user->email);
+ Mail::assertSent(CheckinAssetMail::class, function (CheckinAssetMail $mail) use ($user) {
+ return $mail->hasTo($user->email) && $mail->hasCc('[email protected]');
});
}