Skip to content
Snippets Groups Projects
Commit c4425910 authored by Andrey Postnikov's avatar Andrey Postnikov
Browse files

upgrade deprecation to 10.3.0

parent 0149f028
Branches
Tags
1 merge request!5759Move work from #3405696
......@@ -388,7 +388,7 @@ public function testEscapingAssertions() {
* @group legacy
*/
public function testResponseHeaderEquals() {
$this->expectDeprecation('Calling Drupal\Tests\WebAssert::responseHeaderEquals() with NULL as the $value argument is deprecated in drupal:10.2.0 and will be removed in drupal:11.0.0. Use \Drupal\Tests\WebAssert::responseHeaderDoesNotExist instead. See https://www.drupal.org/node/3408184');
$this->expectDeprecation('Calling Drupal\Tests\WebAssert::responseHeaderEquals() with NULL as the $value argument is deprecated in drupal:10.3.0 and will be removed in drupal:11.0.0. Use \Drupal\Tests\WebAssert::responseHeaderDoesNotExist instead. See https://www.drupal.org/node/3408184');
$this->assertSession()->responseHeaderEquals('Header-Not-Appearing-In-This-Test', NULL);
}
......
......@@ -86,7 +86,7 @@ protected function submitForm(array $edit, $submit, $form_html_id = NULL) {
$field_type = $field->getAttribute('type');
if ($field_type === 'checkbox' && !is_bool($value)) {
@trigger_error("Setting a checkbox with a non-boolean value in " . __METHOD__ . "() is deprecated in drupal:10.2.0 and will be removed in drupal:11.0.0. Checkbox '$name' was set with value '$value'. See https://www.drupal.org/node/3408184", E_USER_DEPRECATED);
@trigger_error("Setting a checkbox with a non-boolean value in " . __METHOD__ . "() is deprecated in drupal:10.3.0 and will be removed in drupal:11.0.0. Checkbox '$name' was set with value '$value'. See https://www.drupal.org/node/3408184", E_USER_DEPRECATED);
$value = (bool) $value;
}
......
......@@ -71,7 +71,7 @@ protected function cleanUrl($url, $include_query = FALSE) {
*/
public function responseHeaderEquals(string $name, $value) {
if (is_null($value)) {
@trigger_error('Calling ' . __METHOD__ . '() with NULL as the $value argument is deprecated in drupal:10.2.0 and will be removed in drupal:11.0.0. Use \Drupal\Tests\WebAssert::responseHeaderDoesNotExist instead. See https://www.drupal.org/node/3408184', E_USER_DEPRECATED);
@trigger_error('Calling ' . __METHOD__ . '() with NULL as the $value argument is deprecated in drupal:10.3.0 and will be removed in drupal:11.0.0. Use \Drupal\Tests\WebAssert::responseHeaderDoesNotExist instead. See https://www.drupal.org/node/3408184', E_USER_DEPRECATED);
$this->responseHeaderDoesNotExist($name);
return;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment