You are here

protected function EntityEmbedTestBase::pressEditorButton in Entity Embed 8

Clicks a CKEditor button.

Parameters

string $name: The name of the button, such as drupalink, source, etc.

7 calls to EntityEmbedTestBase::pressEditorButton()
CKEditorIntegrationTest::assertCkeditorUndoOrRedo in tests/src/FunctionalJavascript/CKEditorIntegrationTest.php
Asserts the consequences of CKEditor undo/redo actions.
CKEditorIntegrationTest::testIntegration in tests/src/FunctionalJavascript/CKEditorIntegrationTest.php
Test integration with Filter, Editor and Ckeditor.
ContentTranslationTest::testHostEntityLangcode in tests/src/FunctionalJavascript/ContentTranslationTest.php
Tests the host entity's langcode is available in EntityEmbedDialog.
MediaImageTest::testAltAndTitle in tests/src/FunctionalJavascript/MediaImageTest.php
Tests alt and title overriding for embedded images.
MediaImageTest::testCkeditorWidgetHasEditableCaption in tests/src/FunctionalJavascript/MediaImageTest.php
Tests caption editing in the CKEditor widget.

... See full list

File

tests/src/FunctionalJavascript/EntityEmbedTestBase.php, line 47

Class

EntityEmbedTestBase
Base class for all entity_embed tests.

Namespace

Drupal\Tests\entity_embed\FunctionalJavascript

Code

protected function pressEditorButton($name) {
  $this
    ->getSession()
    ->switchToIFrame();
  $this
    ->assertSession()
    ->waitForElementVisible('css', 'a.cke_button__' . $name)
    ->click();
}