function InlineBlockTestBase::setUp

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

Overrides BrowserTestBase::setUp

1 call to InlineBlockTestBase::setUp()
InlineBlockPrivateFilesTest::setUp in core/modules/layout_builder/tests/src/FunctionalJavascript/InlineBlockPrivateFilesTest.php
1 method overrides InlineBlockTestBase::setUp()
InlineBlockPrivateFilesTest::setUp in core/modules/layout_builder/tests/src/FunctionalJavascript/InlineBlockPrivateFilesTest.php

File

core/modules/layout_builder/tests/src/FunctionalJavascript/InlineBlockTestBase.php, line 47

Class

InlineBlockTestBase
Base class for testing inline blocks.

Namespace

Drupal\Tests\layout_builder\FunctionalJavascript

Code

protected function setUp() {
    parent::setUp();
    $this->drupalPlaceBlock('local_tasks_block');
    $this->createContentType([
        'type' => 'bundle_with_section_field',
        'new_revision' => TRUE,
    ]);
    $this->createNode([
        'type' => 'bundle_with_section_field',
        'title' => 'The node title',
        'body' => [
            [
                'value' => 'The node body',
            ],
        ],
    ]);
    $this->createNode([
        'type' => 'bundle_with_section_field',
        'title' => 'The node2 title',
        'body' => [
            [
                'value' => 'The node2 body',
            ],
        ],
    ]);
    $this->createBlockContentType('basic', 'Basic block');
    $this->blockStorage = $this->container
        ->get('entity_type.manager')
        ->getStorage('block_content');
}

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