function EditorAdminTest::testSwitchEditorToNone

Same name in other branches
  1. 9 core/modules/editor/tests/src/Functional/EditorAdminTest.php \Drupal\Tests\editor\Functional\EditorAdminTest::testSwitchEditorToNone()
  2. 10 core/modules/editor/tests/src/Functional/EditorAdminTest.php \Drupal\Tests\editor\Functional\EditorAdminTest::testSwitchEditorToNone()
  3. 11.x core/modules/editor/tests/src/Functional/EditorAdminTest.php \Drupal\Tests\editor\Functional\EditorAdminTest::testSwitchEditorToNone()

Tests switching text editor to none does not throw a TypeError.

File

core/modules/editor/tests/src/Functional/EditorAdminTest.php, line 161

Class

EditorAdminTest
Tests administration of text editors.

Namespace

Drupal\Tests\editor\Functional

Code

public function testSwitchEditorToNone() {
    $this->enableUnicornEditor();
    $this->drupalLogin($this->adminUser);
    $this->drupalGet('admin/config/content/formats/manage/filtered_html');
    $edit = $this->selectUnicornEditor();
    // Switch editor to 'None'.
    $edit = [
        'editor[editor]' => '',
    ];
    $this->submitForm($edit, 'Configure');
    $this->submitForm($edit, 'Save configuration');
}

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