function DrupalSelenium2Driver::dragTo
Same name in other branches
- 10 core/tests/Drupal/FunctionalJavascriptTests/DrupalSelenium2Driver.php \Drupal\FunctionalJavascriptTests\DrupalSelenium2Driver::dragTo()
- 11.x core/tests/Drupal/FunctionalJavascriptTests/DrupalSelenium2Driver.php \Drupal\FunctionalJavascriptTests\DrupalSelenium2Driver::dragTo()
File
-
core/
tests/ Drupal/ FunctionalJavascriptTests/ DrupalSelenium2Driver.php, line 215
Class
- DrupalSelenium2Driver
- Provides a driver for Selenium testing.
Namespace
Drupal\FunctionalJavascriptTestsCode
public function dragTo($sourceXpath, $destinationXpath) {
// Ensure both the source and destination exist at this point.
$this->getWebDriverSession()
->element('xpath', $sourceXpath);
$this->getWebDriverSession()
->element('xpath', $destinationXpath);
try {
parent::dragTo($sourceXpath, $destinationXpath);
} catch (Exception $e) {
// Do not care if this fails for any reason. It is a source of random
// fails. The calling code should be doing assertions on the results of
// dragging anyway. See upstream issues:
// - https://github.com/minkphp/MinkSelenium2Driver/issues/97
// - https://github.com/minkphp/MinkSelenium2Driver/issues/51
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.