You are here

public function ErrorHandlerTest::assertNoErrorMessage in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php \Drupal\Tests\system\Functional\System\ErrorHandlerTest::assertNoErrorMessage()
  2. 9 core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php \Drupal\Tests\system\Functional\System\ErrorHandlerTest::assertNoErrorMessage()

Helper function: assert that the error message is not found.

@internal

2 calls to ErrorHandlerTest::assertNoErrorMessage()
ErrorHandlerTest::testErrorHandler in core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php
Tests the error handler.
ErrorHandlerTest::testExceptionHandler in core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php
Tests the exception handler.

File

core/modules/system/tests/src/Functional/System/ErrorHandlerTest.php, line 166

Class

ErrorHandlerTest
Performs tests on the Drupal error and exception handler.

Namespace

Drupal\Tests\system\Functional\System

Code

public function assertNoErrorMessage(array $error) : void {
  $message = new FormattableMarkup('%type: @message in %function (line ', $error);
  $this
    ->assertSession()
    ->responseNotContains($message);
}