function EditModeTest::pressToolbarEditButton

Same name in other branches
  1. 8.9.x core/modules/contextual/tests/src/FunctionalJavascript/EditModeTest.php \Drupal\Tests\contextual\FunctionalJavascript\EditModeTest::pressToolbarEditButton()
  2. 10 core/modules/contextual/tests/src/FunctionalJavascript/EditModeTest.php \Drupal\Tests\contextual\FunctionalJavascript\EditModeTest::pressToolbarEditButton()
  3. 11.x core/modules/contextual/tests/src/FunctionalJavascript/EditModeTest.php \Drupal\Tests\contextual\FunctionalJavascript\EditModeTest::pressToolbarEditButton()

Presses the toolbar edit mode.

1 call to EditModeTest::pressToolbarEditButton()
EditModeTest::testEditModeEnableDisable in core/modules/contextual/tests/src/FunctionalJavascript/EditModeTest.php
Tests enabling and disabling edit mode.

File

core/modules/contextual/tests/src/FunctionalJavascript/EditModeTest.php, line 96

Class

EditModeTest
Tests edit mode.

Namespace

Drupal\Tests\contextual\FunctionalJavascript

Code

protected function pressToolbarEditButton() {
    $edit_button = $this->getSession()
        ->getPage()
        ->find('css', '#toolbar-bar div.contextual-toolbar-tab button');
    $edit_button->press();
}

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