You are here

public function DeleteRoleTest::setUpRole in Workbench Access 8

Sets up role that has access to content.

Parameters

string $name: The machine name for the role: the role id.

1 call to DeleteRoleTest::setUpRole()
DeleteRoleTest::testRoleDelete in tests/src/Functional/DeleteRoleTest.php
Tests that deleting a role clears their data from storage.

File

tests/src/Functional/DeleteRoleTest.php, line 87

Class

DeleteRoleTest
Tests for deleting a role and removing associated data.

Namespace

Drupal\Tests\workbench_access\Functional

Code

public function setUpRole($name) {
  $this
    ->createRole([
    'access administration pages',
    'create page content',
    'edit any page content',
    'administer menu',
    'delete any page content',
    'use workbench access',
  ], $name);
}