function MemoryTestRunResultsStorage::getCurrentTestRunState

File

core/tests/Drupal/TestTools/TestRunner/MemoryTestRunResultsStorage.php, line 102

Class

MemoryTestRunResultsStorage
Implements an in-memory test run results storage.

Namespace

Drupal\TestTools\TestRunner

Code

public function getCurrentTestRunState(TestRun $test_run) : array {
  // Identify the latest 'message_id' given the test_id.
  $max_message_id = count($this->testId[$test_run->id()]['log']) - 1;
  return [
    'db_prefix' => $this->testId[$test_run->id()]['last_prefix'],
    'test_class' => $this->testId[$test_run->id()]['log'][$max_message_id]['test_class'],
  ];
}

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