Skip to content

Commit

Permalink
Added tests
Browse files Browse the repository at this point in the history
  • Loading branch information
imonroe committed Sep 12, 2023
1 parent 930981d commit 43718c2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
12 changes: 12 additions & 0 deletions tests/codeception/acceptance/Media/MediaPermissionsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,18 @@ public function testAdminPerms(AcceptanceTester $I) {
$I->canSee('Embed Code');
}

/**
* Test site embedder perms
*/
public function testSiteEmbedderPerms(AcceptanceTester $I) {
$user = $I->createUserWithRoles(['su_site_embedder', 'site_manager']);
$I->logInAs($user->getAccountName());
$I->amOnPage('/media/add/embeddable');
$I->canSeeResponseCodeIs(200);
$I->canSee('oEmbed URL');
$I->canSee('Embed Code');
}

/**
* Test site manager perms
*/
Expand Down
1 change: 1 addition & 0 deletions tests/codeception/acceptance/Users/RolesCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function testRolesExist(AcceptanceTester $I) {
$I->canSee('Site Builder');
$I->canSee('Site Developer');
$I->canSee('Administrator');
$I->canSee('Site Embedder');
}

/**
Expand Down

0 comments on commit 43718c2

Please sign in to comment.