function ModerationStateAccessTest::setUp
Same name in other branches
- 9 core/modules/content_moderation/tests/src/Functional/ModerationStateAccessTest.php \Drupal\Tests\content_moderation\Functional\ModerationStateAccessTest::setUp()
- 10 core/modules/content_moderation/tests/src/Functional/ModerationStateAccessTest.php \Drupal\Tests\content_moderation\Functional\ModerationStateAccessTest::setUp()
- 11.x core/modules/content_moderation/tests/src/Functional/ModerationStateAccessTest.php \Drupal\Tests\content_moderation\Functional\ModerationStateAccessTest::setUp()
Overrides BrowserTestBase::setUp
File
-
core/
modules/ content_moderation/ tests/ src/ Functional/ ModerationStateAccessTest.php, line 35
Class
- ModerationStateAccessTest
- Tests the view access control handler for moderation state entities.
Namespace
Drupal\Tests\content_moderation\FunctionalCode
protected function setUp() {
parent::setUp();
$node_type = NodeType::create([
'type' => 'test',
'label' => 'Test',
]);
$node_type->save();
$workflow = $this->createEditorialWorkflow();
$workflow->getTypePlugin()
->addEntityTypeAndBundle('node', 'test');
$workflow->save();
$this->container
->get('module_installer')
->install([
'content_moderation_test_views',
]);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.