Skip to content
Snippets Groups Projects
Verified Commit 511ecab8 authored by Dave Long's avatar Dave Long
Browse files

Issue #3427054 by mondrake: Replace calls to ::expectError*() in MachineNameTest

parent dc85a3c6
No related branches found
No related tags found
No related merge requests found
...@@ -2217,14 +2217,6 @@ parameters: ...@@ -2217,14 +2217,6 @@ parameters:
count: 1 count: 1
path: tests/Drupal/KernelTests/Core/Image/ToolkitGdTest.php path: tests/Drupal/KernelTests/Core/Image/ToolkitGdTest.php
-
message: """
#^Call to deprecated method expectErrorMessage\\(\\) of class PHPUnit\\\\Framework\\\\TestCase\\:
https\\://github\\.com/sebastianbergmann/phpunit/issues/5062$#
"""
count: 1
path: tests/Drupal/KernelTests/Core/Render/Element/MachineNameTest.php
- -
message: "#^Variable \\$value in isset\\(\\) always exists and is not nullable\\.$#" message: "#^Variable \\$value in isset\\(\\) always exists and is not nullable\\.$#"
count: 1 count: 1
......
...@@ -66,7 +66,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) { ...@@ -66,7 +66,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
*/ */
public function testMachineNameOrderException() { public function testMachineNameOrderException() {
$this->expectException(\LogicException::class); $this->expectException(\LogicException::class);
$this->expectErrorMessage('The machine name element "test_machine_name" is defined before the source element "test_source", it must be defined after or the source element must specify an id.'); $this->expectExceptionMessage('The machine name element "test_machine_name" is defined before the source element "test_source", it must be defined after or the source element must specify an id.');
$form = \Drupal::formBuilder()->getForm($this); $form = \Drupal::formBuilder()->getForm($this);
$this->render($form); $this->render($form);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment