protected function DevelTwigExtensionTest::setUp in Devel 8.3
Same name and namespace in other branches
- 8 tests/src/Kernel/DevelTwigExtensionTest.php \Drupal\Tests\devel\Kernel\DevelTwigExtensionTest::setUp()
- 8.2 tests/src/Kernel/DevelTwigExtensionTest.php \Drupal\Tests\devel\Kernel\DevelTwigExtensionTest::setUp()
- 4.x tests/src/Kernel/DevelTwigExtensionTest.php \Drupal\Tests\devel\Kernel\DevelTwigExtensionTest::setUp()
Overrides KernelTestBase::setUp
File
- tests/
src/ Kernel/ DevelTwigExtensionTest.php, line 39
Class
- DevelTwigExtensionTest
- Tests Twig extensions.
Namespace
Drupal\Tests\devel\KernelCode
protected function setUp() {
parent::setUp();
$this
->installEntitySchema('user');
$this
->installSchema('system', 'sequences');
$devel_role = Role::create([
'id' => 'admin',
'permissions' => [
'access devel information',
],
]);
$devel_role
->save();
$this->develUser = User::create([
'name' => $this
->randomMachineName(),
'roles' => [
$devel_role
->id(),
],
]);
$this->develUser
->save();
}