From e3da33c00a610bd1c1618fce147063760dbac1d5 Mon Sep 17 00:00:00 2001 From: Nathaniel Catchpole Date: Thu, 17 May 2018 13:14:29 +0100 Subject: [PATCH] Issue #2972992 by alexpott: Handle Mink deprecations --- .../Drupal/Tests/Listeners/DeprecationListenerTrait.php | 2 -- core/tests/Drupal/Tests/WebAssert.php | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php index b0172e92f2b..f2737571b38 100644 --- a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php +++ b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php @@ -114,8 +114,6 @@ trait DeprecationListenerTrait { 'Using "null" for the value of node "count" of "Drupal\Core\Template\TwigNodeTrans" is deprecated since version 1.25 and will be removed in 2.0.', 'Using "null" for the value of node "options" of "Drupal\Core\Template\TwigNodeTrans" is deprecated since version 1.25 and will be removed in 2.0.', 'Using "null" for the value of node "plural" of "Drupal\Core\Template\TwigNodeTrans" is deprecated since version 1.25 and will be removed in 2.0.', - 'The Behat\Mink\Selector\SelectorsHandler::xpathLiteral method is deprecated as of 1.7 and will be removed in 2.0. Use \Behat\Mink\Selector\Xpath\Escaper::escapeLiteral instead when building Xpath or pass the unescaped value when using the named selector.', - 'Passing an escaped locator to the named selector is deprecated as of 1.7 and will be removed in 2.0. Pass the raw value instead.', 'Providing settings under \'handler_settings\' is deprecated and will be removed before 9.0.0. Move the settings in the root of the configuration array. See https://www.drupal.org/node/2870971.', 'AssertLegacyTrait::getRawContent() is scheduled for removal in Drupal 9.0.0. Use $this->getSession()->getPage()->getContent() instead.', 'AssertLegacyTrait::getAllOptions() is scheduled for removal in Drupal 9.0.0. Use $element->findAll(\'xpath\', \'option\') instead.', diff --git a/core/tests/Drupal/Tests/WebAssert.php b/core/tests/Drupal/Tests/WebAssert.php index 313952bfe80..e3d06d83549 100644 --- a/core/tests/Drupal/Tests/WebAssert.php +++ b/core/tests/Drupal/Tests/WebAssert.php @@ -115,7 +115,7 @@ class WebAssert extends MinkWebAssert { $container = $container ?: $this->session->getPage(); $node = $container->find('named', [ 'select', - $this->session->getSelectorsHandler()->xpathLiteral($select), + $select, ]); if ($node === NULL) { @@ -145,7 +145,7 @@ class WebAssert extends MinkWebAssert { $container = $container ?: $this->session->getPage(); $select_field = $container->find('named', [ 'select', - $this->session->getSelectorsHandler()->xpathLiteral($select), + $select, ]); if ($select_field === NULL) { @@ -178,7 +178,7 @@ class WebAssert extends MinkWebAssert { $container = $container ?: $this->session->getPage(); $select_field = $container->find('named', [ 'select', - $this->session->getSelectorsHandler()->xpathLiteral($select), + $select, ]); if ($select_field === NULL) {