function LayoutDisplayTest::setUp

Same name and namespace in other branches
  1. 8.9.x core/modules/layout_builder/tests/src/Functional/LayoutDisplayTest.php \Drupal\Tests\layout_builder\Functional\LayoutDisplayTest::setUp()
  2. 10 core/modules/layout_builder/tests/src/Functional/LayoutDisplayTest.php \Drupal\Tests\layout_builder\Functional\LayoutDisplayTest::setUp()
  3. 11.x core/modules/layout_builder/tests/src/Functional/LayoutDisplayTest.php \Drupal\Tests\layout_builder\Functional\LayoutDisplayTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/layout_builder/tests/src/Functional/LayoutDisplayTest.php, line 27

Class

LayoutDisplayTest
Tests functionality of the entity view display with regard to Layout Builder.

Namespace

Drupal\Tests\layout_builder\Functional

Code

protected function setUp() : void {
    parent::setUp();
    $this->createContentType([
        'type' => 'bundle_with_section_field',
    ]);
    $this->createNode([
        'type' => 'bundle_with_section_field',
    ]);
    $this->drupalLogin($this->drupalCreateUser([
        'configure any layout',
        'administer node display',
        'administer display modes',
    ], 'foobar'));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.