TenantAtlas/apps/platform/tests/Feature/RequiredPermissions/RequiredPermissionsCopyActionsTest.php
Ahmed Darrazi e4db44f606
Some checks failed
PR Fast Feedback / fast-feedback (pull_request) Failing after 1m27s
feat: complete workspace-first environment routing cutover
2026-05-07 23:46:45 +02:00

27 lines
1.0 KiB
PHP

<?php
declare(strict_types=1);
use App\Models\ManagedEnvironment;
use App\Support\Links\RequiredPermissionsLinks;
it('renders guidance, admin consent link, re-run verification, and copy actions on the required permissions page', function (): void {
$tenant = ManagedEnvironment::factory()->create([
'external_id' => 'tenant-copy-actions-a',
'app_client_id' => null,
]);
[$user, $tenant] = createUserWithTenant(tenant: $tenant, role: 'readonly', ensureDefaultMicrosoftProviderConnection: false);
$this->actingAs($user)
->get(RequiredPermissionsLinks::requiredPermissions($tenant))
->assertSuccessful()
->assertSee('Guidance')
->assertSee('Who can fix this?', false)
->assertSee('Admin consent guide')
->assertSee('learn.microsoft.com/en-us/entra/identity/enterprise-apps/grant-admin-consent', false)
->assertSee('Re-run verification')
->assertSee('Copy missing application permissions')
->assertSee('Copy missing delegated permissions');
});