You are here

protected function NodeDisplayConfigurableTest::setUp in Drupal 10

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

File

core/modules/node/tests/src/Functional/NodeDisplayConfigurableTest.php, line 31

Class

NodeDisplayConfigurableTest
Tests making node base fields' displays configurable.

Namespace

Drupal\Tests\node\Functional

Code

protected function setUp() : void {
  parent::setUp();
  $data = $this
    ->getProvidedData();
  $theme = reset($data);
  \Drupal::service('theme_installer')
    ->install([
    $theme,
  ]);
  $this
    ->config('system.theme')
    ->set('default', $theme)
    ->save();
  $settings = [
    'theme' => $theme,
    'region' => 'content',
    'weight' => -100,
  ];
  $this
    ->drupalPlaceBlock('page_title_block', $settings);
}