mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-26 06:04:08 -08:00
Scaffold additional tests
This commit is contained in:
parent
307b39bd38
commit
852b0b3f11
|
@ -11,6 +11,36 @@ class AssetCheckinTest extends TestCase
|
|||
{
|
||||
use InteractsWithSettings;
|
||||
|
||||
public function testCheckingInAssetRequiresCorrectPermission()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testAssetCheckedOutToAssetCanBeCheckedIn()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testAssetCheckedOutToLocationCanBeCheckedIn()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testAssetCheckedOutToUserCanBeCheckedIn()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testCheckInEmailSentToUserIfSettingEnabled()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testCheckInEmailNotSentToUserIfSettingDisabled()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testLastCheckInFieldIsSetOnCheckin()
|
||||
{
|
||||
$admin = User::factory()->superuser()->create();
|
||||
|
|
|
@ -24,13 +24,23 @@ class AssetCheckinTest extends TestCase
|
|||
->assertForbidden();
|
||||
}
|
||||
|
||||
public function testAssetCanBeCheckedIn()
|
||||
public function testAssetCheckedOutToAssetCanBeCheckedIn()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testAssetCheckedOutToLocationCanBeCheckedIn()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
}
|
||||
|
||||
public function testAssetCheckedOutToUserCanBeCheckedIn()
|
||||
{
|
||||
Event::fake([CheckoutableCheckedIn::class]);
|
||||
|
||||
$admin = User::factory()->checkinAssets()->create();
|
||||
$user = User::factory()->create();
|
||||
$asset = Asset::factory()->assignedToUser($user)->create(['last_checkin' => null]);
|
||||
$asset = Asset::factory()->assignedToUser($user)->create();
|
||||
|
||||
$this->assertTrue($asset->assignedTo->is($user));
|
||||
|
||||
|
|
Loading…
Reference in a new issue