mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-26 14:09:43 -08:00
8c6ecd35ec
Signed-off-by: snipe <snipe@snipe.net>
24 lines
543 B
PHP
24 lines
543 B
PHP
<?php
|
|
|
|
namespace Tests\Feature\Consumables\Ui;
|
|
|
|
use App\Models\User;
|
|
use Tests\TestCase;
|
|
|
|
class ConsumableIndexTest extends TestCase
|
|
{
|
|
public function testPermissionRequiredToViewConsumablesList()
|
|
{
|
|
$this->actingAs(User::factory()->create())
|
|
->get(route('consumables.index'))
|
|
->assertForbidden();
|
|
}
|
|
|
|
public function testUserCanListConsumables()
|
|
{
|
|
$this->actingAs(User::factory()->superuser()->create())
|
|
->get(route('consumables.index'))
|
|
->assertOk();
|
|
}
|
|
}
|