You are here

protected function MoveBlockFormTest::findRowHandle in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/layout_builder/tests/src/FunctionalJavascript/MoveBlockFormTest.php \Drupal\Tests\layout_builder\FunctionalJavascript\MoveBlockFormTest::findRowHandle()
  2. 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.

File

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

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");
}