function LayoutBuilderDisableInteractionsTest::movePointerTo

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

Moves mouse pointer to location of $selector.

Parameters

string $selector: CSS selector.

1 call to LayoutBuilderDisableInteractionsTest::movePointerTo()
LayoutBuilderDisableInteractionsTest::assertContextualLinkRetainsMouseup in core/modules/layout_builder/tests/src/FunctionalJavascript/LayoutBuilderDisableInteractionsTest.php
Makes sure contextual links respond to mouseup event.

File

core/modules/layout_builder/tests/src/FunctionalJavascript/LayoutBuilderDisableInteractionsTest.php, line 324

Class

LayoutBuilderDisableInteractionsTest
Tests the Layout Builder disables interactions of rendered blocks.

Namespace

Drupal\Tests\layout_builder\FunctionalJavascript

Code

protected function movePointerTo($selector) {
    $driver_session = $this->getSession()
        ->getDriver()
        ->getWebDriverSession();
    $element = $driver_session->element('css selector', $selector);
    $driver_session->moveto([
        'element' => $element->getID(),
    ]);
}

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