You are here

protected function WorkflowCustomStateTransitionAccessTest::setUp in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/workflows/tests/src/Functional/WorkflowCustomStateTransitionAccessTest.php \Drupal\Tests\workflows\Functional\WorkflowCustomStateTransitionAccessTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/workflows/tests/src/Functional/WorkflowCustomStateTransitionAccessTest.php, line 45

Class

WorkflowCustomStateTransitionAccessTest
Test custom provided workflow access for state/transition operations.

Namespace

Drupal\Tests\workflows\Functional

Code

protected function setUp() {
  parent::setUp();
  $this->adminUser = $this
    ->createUser([
    'administer workflows',
  ]);
  $this->testWorkflow = Workflow::create([
    'label' => 'Test workflow',
    'id' => 'test_type',
    'type' => 'workflow_custom_access_type',
  ]);
  $this->testWorkflow
    ->save();
}