function SimpletestTestRunResultsStorage::validateTestingResultsEnvironment

Same name and namespace in other branches
  1. 11.x core/lib/Drupal/Core/Test/SimpletestTestRunResultsStorage.php \Drupal\Core\Test\SimpletestTestRunResultsStorage::validateTestingResultsEnvironment()

Checks if the test run storage is valid.

Return value

bool TRUE when the storage is valid and ready for use, FALSE otherwise.

Overrides TestRunResultsStorageInterface::validateTestingResultsEnvironment

File

core/lib/Drupal/Core/Test/SimpletestTestRunResultsStorage.php, line 162

Class

SimpletestTestRunResultsStorage
Implements a test run results storage compatible with legacy Simpletest.

Namespace

Drupal\Core\Test

Code

public function validateTestingResultsEnvironment() : bool {
    $schema = $this->connection
        ->schema();
    return $schema->tableExists('simpletest') && $schema->tableExists('simpletest_test_id');
}

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