mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
Implement test
This commit is contained in:
parent
67c4fa2966
commit
482ebfbb68
|
@ -63,8 +63,16 @@ class AssetCheckoutTest extends TestCase
|
||||||
|
|
||||||
public function testAssetCannotBeCheckedOutToItself()
|
public function testAssetCannotBeCheckedOutToItself()
|
||||||
{
|
{
|
||||||
// @todo:
|
$asset = Asset::factory()->create();
|
||||||
$this->markTestIncomplete();
|
|
||||||
|
$this->actingAs(User::factory()->checkoutAssets()->create())
|
||||||
|
->post(route('hardware.checkout.store', $asset), [
|
||||||
|
'checkout_to_type' => 'asset',
|
||||||
|
'assigned_asset' => $asset->id,
|
||||||
|
])
|
||||||
|
->assertSessionHas('error');
|
||||||
|
|
||||||
|
Event::assertNotDispatched(CheckoutableCheckedOut::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testValidationWhenCheckingOutAsset()
|
public function testValidationWhenCheckingOutAsset()
|
||||||
|
|
Loading…
Reference in a new issue