function ErrorHandlerTest::assertErrorMessage
Same name in other branches
- 9 core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php \Drupal\Tests\system\Functional\System\ErrorHandlerTest::assertErrorMessage()
- 10 core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php \Drupal\Tests\system\Functional\System\ErrorHandlerTest::assertErrorMessage()
- 11.x core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php \Drupal\Tests\system\Functional\System\ErrorHandlerTest::assertErrorMessage()
Helper function: assert that the error message is found.
2 calls to ErrorHandlerTest::assertErrorMessage()
- ErrorHandlerTest::testErrorHandler in core/
modules/ system/ tests/ src/ Functional/ System/ ErrorHandlerTest.php - Test the error handler.
- ErrorHandlerTest::testExceptionHandler in core/
modules/ system/ tests/ src/ Functional/ System/ ErrorHandlerTest.php - Test the exception handler.
File
-
core/
modules/ system/ tests/ src/ Functional/ System/ ErrorHandlerTest.php, line 155
Class
- ErrorHandlerTest
- Performs tests on the Drupal error and exception handler.
Namespace
Drupal\Tests\system\Functional\SystemCode
public function assertErrorMessage(array $error) {
$message = new FormattableMarkup('%type: @message in %function (line ', $error);
$this->assertRaw($message, new FormattableMarkup('Found error message: @message.', [
'@message' => $message,
]));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.