function CKEditor5TestTrait::assertVisibleBalloon

Same name and namespace in other branches
  1. 10 core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::assertVisibleBalloon()
  2. 11.x core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::assertVisibleBalloon()

Asserts a particular balloon is visible.

Parameters

string $balloon_content_selector: A CSS selector.

Return value

\Behat\Mink\Element\NodeElement The asserted balloon.

14 calls to CKEditor5TestTrait::assertVisibleBalloon()
ImageTestBase::testAlignment in core/modules/ckeditor5/tests/src/FunctionalJavascript/ImageTestBase.php
Tests alignment integration.
ImageTestBase::testAltTextRequired in core/modules/ckeditor5/tests/src/FunctionalJavascript/ImageTestBase.php
Tests that alt text is required for images.
ImageTestBase::testLinkability in core/modules/ckeditor5/tests/src/FunctionalJavascript/ImageTestBase.php
Tests linkability of the image CKEditor widget.
ImageUrlTest::testImageUrlWidget in core/modules/ckeditor5/tests/src/FunctionalJavascript/ImageUrlTest.php
Tests the Drupal image URL widget.
MediaLibraryTest::testAlt in core/modules/ckeditor5/tests/src/FunctionalJavascript/MediaLibraryTest.php
Ensures that alt text can be changed on Media Library inserted Media.

... See full list

File

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

Class

CKEditor5TestTrait
Provides methods to test CKEditor 5.

Namespace

Drupal\Tests\ckeditor5\Traits

Code

protected function assertVisibleBalloon(string $balloon_content_selector) : NodeElement {
    $this->assertSession()
        ->elementExists('css', '.ck-balloon-panel_visible');
    $selector = ".ck-balloon-panel_visible .ck-balloon-rotator__content > .ck{$balloon_content_selector}";
    $this->assertSession()
        ->elementExists('css', $selector);
    return $this->getSession()
        ->getPage()
        ->find('css', $selector);
}

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