You are here

protected function MoveBlockFormTest::findRowHandle in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/layout_builder/tests/src/FunctionalJavascript/MoveBlockFormTest.php \Drupal\Tests\layout_builder\FunctionalJavascript\MoveBlockFormTest::findRowHandle()

Finds the row handle for a block in the draggable table.

Parameters

string $block_label: The block label.

Return value

\Behat\Mink\Element\NodeElement The row handle element.

1 call to MoveBlockFormTest::findRowHandle()
MoveBlockFormTest::moveBlockWithKeyboard in core/modules/layout_builder/tests/src/FunctionalJavascript/MoveBlockFormTest.php
Moves a block in the draggable table.

File

core/modules/layout_builder/tests/src/FunctionalJavascript/MoveBlockFormTest.php, line 194

Class

MoveBlockFormTest
Tests moving blocks via the form.

Namespace

Drupal\Tests\layout_builder\FunctionalJavascript

Code

protected function findRowHandle($block_label) {
  $assert_session = $this
    ->assertSession();
  return $assert_session
    ->elementExists('css', "[data-drupal-selector=\"edit-components\"] td:contains(\"{$block_label}\") a.tabledrag-handle");
}