You are here

protected function LayoutBuilderTest::setUp in Drupal 10

Same name in this branch
  1. 10 core/modules/layout_builder/tests/src/Functional/LayoutBuilderTest.php \Drupal\Tests\layout_builder\Functional\LayoutBuilderTest::setUp()
  2. 10 core/modules/layout_builder/tests/src/FunctionalJavascript/LayoutBuilderTest.php \Drupal\Tests\layout_builder\FunctionalJavascript\LayoutBuilderTest::setUp()
Same name and namespace in other branches
  1. 8 core/modules/layout_builder/tests/src/Functional/LayoutBuilderTest.php \Drupal\Tests\layout_builder\Functional\LayoutBuilderTest::setUp()
  2. 9 core/modules/layout_builder/tests/src/Functional/LayoutBuilderTest.php \Drupal\Tests\layout_builder\Functional\LayoutBuilderTest::setUp()

File

core/modules/layout_builder/tests/src/Functional/LayoutBuilderTest.php, line 42

Class

LayoutBuilderTest
Tests the Layout Builder UI.

Namespace

Drupal\Tests\layout_builder\Functional

Code

protected function setUp() : void {
  parent::setUp();
  $this
    ->drupalPlaceBlock('local_tasks_block');

  // Create two nodes.
  $this
    ->createContentType([
    'type' => 'bundle_with_section_field',
    'name' => 'Bundle with section field',
  ]);
  $this
    ->createNode([
    'type' => 'bundle_with_section_field',
    'title' => 'The first node title',
    'body' => [
      [
        'value' => 'The first node body',
      ],
    ],
  ]);
  $this
    ->createNode([
    'type' => 'bundle_with_section_field',
    'title' => 'The second node title',
    'body' => [
      [
        'value' => 'The second node body',
      ],
    ],
  ]);
}