3
0
mirror of https://github.com/snipe/snipe-it.git synced 2026-03-30 12:24:53 +00:00

Add failing test

This commit is contained in:
Marcus Moore
2025-03-20 13:26:06 -07:00
parent a398c4ab84
commit d645b42e12

View File

@ -0,0 +1,27 @@
<?php
namespace Tests\Feature\Checkouts\Ui;
use App\Models\User;
use Tests\TestCase;
class BulkAssetCheckoutTest extends TestCase
{
public function testHandleMissingModelBeingIncluded()
{
$this->actingAs(User::factory()->checkoutAssets()->create())
->post(route('hardware.bulkcheckout.store'), [
'selected_assets' => [
1,
9999999,
],
'checkout_to_type' => 'user',
'assigned_user' => User::factory()->create()->id,
'assigned_asset' => null,
'checkout_at' => null,
'expected_checkin' => null,
'note' => null,
])
->assertSessionHas('error', trans_choice('admin/hardware/message.multi-checkout.error', 2));
}
}