function simpletest_log_read

Same name in other branches
  1. 7.x modules/simpletest/simpletest.module \simpletest_log_read()

Reads the error log and reports any errors as assertion failures.

The errors in the log should only be fatal errors since any other errors will have been recorded by the error handler.

Parameters

$test_id: The test ID to which the log relates.

$database_prefix: The database prefix to which the log relates.

$test_class: The test class to which the log relates.

Return value

bool Whether any fatal errors were found.

Deprecated

in drupal:8.8.0 and is removed from drupal:9.0.0. Use \Drupal\Core\Test\TestDatabase::logRead() instead.

See also

https://www.drupal.org/node/3075252

File

core/modules/simpletest/simpletest.module, line 461

Code

function simpletest_log_read($test_id, $database_prefix, $test_class) {
    @trigger_error(__FUNCTION__ . ' is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use \\Drupal\\Core\\Test\\TestDatabase::logRead() instead. See https://www.drupal.org/node/3075252', E_USER_DEPRECATED);
    $test_db = new TestDatabase($database_prefix);
    return $test_db->logRead($test_id, $test_class);
}

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