function CKEditorIntegrationTest::assertContextMenuItemNotExists

Asserts that a context menu item does not exist by aria-label attribute.

Parameters

string $label: The `aria-label` attribute value of the context menu item.

1 call to CKEditorIntegrationTest::assertContextMenuItemNotExists()
CKEditorIntegrationTest::testLinkability in core/modules/media/tests/src/FunctionalJavascript/CKEditorIntegrationTest.php
Tests linkability of the CKEditor widget.

File

core/modules/media/tests/src/FunctionalJavascript/CKEditorIntegrationTest.php, line 1497

Class

CKEditorIntegrationTest
@coversDefaultClass \Drupal\media\Plugin\CKEditorPlugin\DrupalMedia @group media

Namespace

Drupal\Tests\media\FunctionalJavascript

Code

protected function assertContextMenuItemNotExists($label) {
    $this->assertSession()
        ->elementNotExists('xpath', '//a[@aria-label="' . $label . '"]');
}

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