Commit 028957b6 authored by catch's avatar catch
Browse files

Issue #3335343 by Chris64: Error Phpunit test 9.5.x: PHP 8.1 & pgsql-14.1 :...

Issue #3335343 by Chris64: Error Phpunit test 9.5.x: PHP 8.1 & pgsql-14.1 : Passing an escaped locator to the named selector is deprecated as of 1.7
parent 46c834d2
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -4,7 +4,6 @@

use Behat\Mink\Element\NodeElement;
use Behat\Mink\Exception\ExpectationException;
use Behat\Mink\Selector\Xpath\Escaper;
use Drupal\Component\Render\FormattableMarkup;
use Drupal\Component\Utility\Xss;
use Drupal\KernelTests\AssertLegacyTrait as BaseAssertLegacyTrait;
@@ -759,7 +758,7 @@ protected function assertFieldsByValue($fields, $value = NULL, $message = '') {
            // Input element with correct value.
            $found = TRUE;
          }
          elseif ($field->find('xpath', '//option[@value = ' . (new Escaper())->escapeLiteral($value) . ' and @selected = "selected"]')) {
          elseif ($field->find('xpath', '//option[@value = ' . $value . ' and @selected = "selected"]')) {
            // Select element with an option.
            $found = TRUE;
          }