22 lines
557 B
PHP
22 lines
557 B
PHP
<?php
|
|
|
|
use App\Models\User;
|
|
use Illuminate\Foundation\Testing\RefreshDatabase;
|
|
|
|
use function Pest\Laravel\actingAs;
|
|
|
|
uses(RefreshDatabase::class);
|
|
|
|
describe('index method', function () {
|
|
it('only allows those assigned to monitor to access this page', function () {
|
|
$user = User::factory()->create();
|
|
actingAs($user);
|
|
$response = $this->get(route('monitor.index'));
|
|
$response->assertForbidden();
|
|
});
|
|
it('needs additional tests written', function () {
|
|
// TODO: Write tests for new monitor pabe
|
|
|
|
});
|
|
});
|