mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
Improve test case
This commit is contained in:
parent
fd60ce1198
commit
fdcb891cbb
|
@ -7,9 +7,7 @@ use App\Models\Asset;
|
|||
use App\Models\AssetModel;
|
||||
use App\Models\Category;
|
||||
use Carbon\Carbon;
|
||||
use App\Notifications\CheckoutAssetNotification;
|
||||
use Illuminate\Support\Facades\Mail;
|
||||
use Illuminate\Support\Facades\Notification;
|
||||
use Tests\TestCase;
|
||||
|
||||
class NotificationTest extends TestCase
|
||||
|
@ -33,8 +31,8 @@ class NotificationTest extends TestCase
|
|||
|
||||
Mail::fake();
|
||||
$asset->checkOut($user, $admin->id);
|
||||
Mail::assertSent(CheckoutAssetMail::class, function ($mail) use ($user) {
|
||||
return $mail->hasTo($user->email);
|
||||
Mail::assertSent(CheckoutAssetMail::class, function (CheckoutAssetMail $mail) use ($user) {
|
||||
return $mail->hasTo($user->email) && $mail->hasSubject(trans('mail.Asset_Checkout_Notification'));
|
||||
});
|
||||
}
|
||||
public function testDefaultEulaIsSentWhenSetInCategory()
|
||||
|
|
Loading…
Reference in a new issue