You are here

protected function FormModeManagerBase::setUp in Form mode manager 8

Same name and namespace in other branches
  1. 8.2 tests/src/Functional/FormModeManagerBase.php \Drupal\Tests\form_mode_manager\Functional\FormModeManagerBase::setUp()

Overrides BrowserTestBase::setUp

1 call to FormModeManagerBase::setUp()
FormModeManagerUiTest::setUp in tests/src/Functional/FormModeManagerUiTest.php
1 method overrides FormModeManagerBase::setUp()
FormModeManagerUiTest::setUp in tests/src/Functional/FormModeManagerUiTest.php

File

tests/src/Functional/FormModeManagerBase.php, line 93

Class

FormModeManagerBase
Provides a test case for form_mode_manager functional tests.

Namespace

Drupal\Tests\form_mode_manager\Functional

Code

protected function setUp() {
  parent::setUp();

  // Setup correct blocks in regions.
  $this
    ->drupalPlaceBlock('local_actions_block');
  $this
    ->drupalPlaceBlock('local_tasks_block');
  $this
    ->drupalPlaceBlock('page_title_block');
  $this->nodeTypeFmm1 = $this
    ->drupalCreateContentType([
    'type' => 'fmm_test',
    'name' => 'Form Mode Manager Test 1',
  ]);
  $this->nodeFormMode = $this
    ->drupalCreateFormMode('node');
  $this->userFormMode = $this
    ->drupalCreateFormMode('user');
  $this->container
    ->get('router.builder')
    ->rebuildIfNeeded();
  $this
    ->drupalLogin($this->rootUser);
  $this
    ->setUpNodeFormMode();
  $this
    ->setUpUserFormMode();
  $this
    ->setUpUsers();
}