You are here

protected function EditorManagerTest::setUp in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/editor/src/Tests/EditorManagerTest.php \Drupal\editor\Tests\EditorManagerTest::setUp()

Performs setup tasks before each individual test method is run.

Overrides KernelTestBase::setUp

File

core/modules/editor/src/Tests/EditorManagerTest.php, line 33
Contains \Drupal\editor\Tests\EditorManagerTest.

Class

EditorManagerTest
Tests detection of text editors and correct generation of attachments.

Namespace

Drupal\editor\Tests

Code

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

  // Install the Filter module.
  $this
    ->installSchema('system', 'url_alias');

  // Add text formats.
  $filtered_html_format = entity_create('filter_format', array(
    'format' => 'filtered_html',
    'name' => 'Filtered HTML',
    'weight' => 0,
    'filters' => array(),
  ));
  $filtered_html_format
    ->save();
  $full_html_format = entity_create('filter_format', array(
    'format' => 'full_html',
    'name' => 'Full HTML',
    'weight' => 1,
    'filters' => array(),
  ));
  $full_html_format
    ->save();
}