function CKEditor5TestTrait::getEditorDataAsDom

Same name in other branches
  1. 9 core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::getEditorDataAsDom()
  2. 10 core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::getEditorDataAsDom()

Gets CKEditor 5 instance data as a PHP DOMDocument.

Return value

\DOMDocument The result of parsing CKEditor 5's data into a PHP DOMDocument.

16 calls to CKEditor5TestTrait::getEditorDataAsDom()
EmphasisTest::testEmphasis in core/modules/ckeditor5/tests/src/FunctionalJavascript/EmphasisTest.php
Ensures that CKEditor italic model is converted to em.
EmphasisTest::testEmphasisArbitraryHtml in core/modules/ckeditor5/tests/src/FunctionalJavascript/EmphasisTest.php
Tests that arbitrary attributes are allowed via GHS.
MediaLibraryTest::testAlt in core/modules/ckeditor5/tests/src/FunctionalJavascript/MediaLibraryTest.php
Ensures that alt text can be changed on Media Library inserted Media.
MediaLibraryTest::testButton in core/modules/ckeditor5/tests/src/FunctionalJavascript/MediaLibraryTest.php
Tests using drupalMedia button to embed media into CKEditor 5.
MediaLinkabilityTest::testLinkability in core/modules/ckeditor5/tests/src/FunctionalJavascript/MediaLinkabilityTest.php
Tests linkability of the media CKEditor widget.

... See full list

File

core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php, line 25

Class

CKEditor5TestTrait
Provides methods to test CKEditor 5.

Namespace

Drupal\Tests\ckeditor5\Traits

Code

protected function getEditorDataAsDom() : \DOMDocument {
    return Html::load($this->getEditorDataAsHtmlString());
}

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