You are here

protected function LayoutClassesTest::setup in Display Suite 8.4

Same name and namespace in other branches
  1. 8.3 tests/src/Functional/LayoutClassesTest.php \Drupal\Tests\ds\Functional\LayoutClassesTest::setup()

File

tests/src/Functional/LayoutClassesTest.php, line 15

Class

LayoutClassesTest
Tests for managing layouts and classes on Field UI screen.

Namespace

Drupal\Tests\ds\Functional

Code

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

  // Set extra fields.
  \Drupal::configFactory()
    ->getEditable('ds_extras.settings')
    ->set('fields_extra', TRUE)
    ->set('fields_extra_list', [
    'node|article|ds_extras_extra_test_field',
    'node|article|ds_extras_second_field',
  ])
    ->save();
  \Drupal::service('entity_field.manager')
    ->clearCachedFieldDefinitions();
}