function DrupalErrorHandlerTestCase::assertNoErrorMessage

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

1 call to DrupalErrorHandlerTestCase::assertNoErrorMessage()
DrupalErrorHandlerTestCase::testErrorHandler in modules/simpletest/tests/error.test
Test the error handler.

File

modules/simpletest/tests/error.test, line 120

Class

DrupalErrorHandlerTestCase
Tests Drupal error and exception handlers.

Code

function assertNoErrorMessage(array $error) {
  $message = t('%type: !message in %function (line ', $error);
  $this->assertNoRaw($message, format_string('Did not find error message: !message.', array(
    '!message' => $message,
  )));
  // Also check that no full path from the error is displayed.
  $this->assertNoRaw($error['%file'], format_string('Full path from error not displayed: %file.', array(
    '%file' => $error['%file'],
  )));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.