mirror of
https://github.com/snipe/snipe-it.git
synced 2025-02-21 03:15:45 -08:00
One more test
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
c3a2cdeee9
commit
590d13061a
|
@ -18,6 +18,14 @@ class LocationsViewTest extends TestCase
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testViewingLocationAssetIndexRequiresPermission()
|
public function testViewingLocationAssetIndexRequiresPermission()
|
||||||
|
{
|
||||||
|
$location = Location::factory()->create();
|
||||||
|
$this->actingAsForApi(User::factory()->create())
|
||||||
|
->getJson(route('api.locations.viewassets', $location->id))
|
||||||
|
->assertForbidden();
|
||||||
|
}
|
||||||
|
|
||||||
|
public function testViewingLocationAssetIndex()
|
||||||
{
|
{
|
||||||
$location = Location::factory()->create();
|
$location = Location::factory()->create();
|
||||||
Asset::factory()->count(3)->assignedToLocation($location)->create();
|
Asset::factory()->count(3)->assignedToLocation($location)->create();
|
||||||
|
|
Loading…
Reference in a new issue