function CKEditor5TestTrait::getBalloonButton
Same name in other branches
- 9 core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::getBalloonButton()
- 10 core/modules/ckeditor5/tests/src/Traits/CKEditor5TestTrait.php \Drupal\Tests\ckeditor5\Traits\CKEditor5TestTrait::getBalloonButton()
Gets a button from the currently visible balloon.
Parameters
string $name: The label of the button to find.
Return value
\Behat\Mink\Element\NodeElement The requested button.
8 calls to CKEditor5TestTrait::getBalloonButton()
- 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.
- MediaLinkabilityTest::testLinkability in core/
modules/ ckeditor5/ tests/ src/ FunctionalJavascript/ MediaLinkabilityTest.php - Tests linkability of the media CKEditor widget.
- MediaTest::testAltDisabled in core/
modules/ ckeditor5/ tests/ src/ FunctionalJavascript/ MediaTest.php - Tests that the image media source's alt_field being disabled is respected.
- MediaTest::testDrupalMediaStyleInDropdown in core/
modules/ ckeditor5/ tests/ src/ FunctionalJavascript/ MediaTest.php - Ensures that Drupal Media Styles can be displayed in a dropdown.
File
-
core/
modules/ ckeditor5/ tests/ src/ Traits/ CKEditor5TestTrait.php, line 131
Class
- CKEditor5TestTrait
- Provides methods to test CKEditor 5.
Namespace
Drupal\Tests\ckeditor5\TraitsCode
protected function getBalloonButton(string $name) : NodeElement {
$button = $this->getSession()
->getPage()
->find('css', '.ck-balloon-panel_visible .ck-balloon-rotator__content')
->find('xpath', "//button[span[text()='{$name}']]");
$this->assertNotEmpty($button);
return $button;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.