protected function BlockFormRoutesAccessTest::setUp in Block permissions 8
Overrides BlockPermissionsBrowserTestBase::setUp
File
- tests/
src/ Functional/ BlockFormRoutesAccessTest.php, line 41
Class
- BlockFormRoutesAccessTest
- Tests Block permissions access control handler for block configuration pages.
Namespace
Drupal\Tests\block_permissions\FunctionalCode
protected function setUp() : void {
parent::setUp();
// User can administer blocks from core.
$this->coreBlocksUser = $this
->drupalCreateUser([
'administer blocks',
"administer block settings for theme {$this->defaultTheme}",
'administer blocks provided by core',
]);
// User can administer blocks from system module.
$this->systemBlocksUser = $this
->drupalCreateUser([
'administer blocks',
"administer block settings for theme {$this->defaultTheme}",
'administer blocks provided by system',
]);
// User can administer blocks from core but in second theme only.
$this->secondThemeUser = $this
->drupalCreateUser([
'administer blocks',
"administer block settings for theme {$this->secondTheme}",
'administer blocks provided by core',
'administer blocks provided by system',
]);
}