You are here

public function CacheCollectorHelper::setCacheMissData in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Core/Cache/CacheCollectorHelper.php \Drupal\Tests\Core\Cache\CacheCollectorHelper::setCacheMissData()
  2. 9 core/tests/Drupal/Tests/Core/Cache/CacheCollectorHelper.php \Drupal\Tests\Core\Cache\CacheCollectorHelper::setCacheMissData()

Sets data to return from a cache miss resolve.

Parameters

string $key: The key being looked for.

mixed $value: The value to return.

File

core/tests/Drupal/Tests/Core/Cache/CacheCollectorHelper.php, line 53

Class

CacheCollectorHelper
Helper class to test the cache collector.

Namespace

Drupal\Tests\Core\Cache

Code

public function setCacheMissData($key, $value) {
  $this->cacheMissData[$key] = $value;
}