You are here

protected function EntityKernelTestBase::getHooksInfo in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/KernelTests/Core/Entity/EntityKernelTestBase.php \Drupal\KernelTests\Core\Entity\EntityKernelTestBase::getHooksInfo()
  2. 9 core/tests/Drupal/KernelTests/Core/Entity/EntityKernelTestBase.php \Drupal\KernelTests\Core\Entity\EntityKernelTestBase::getHooksInfo()

Returns the entity_test hook invocation info.

Return value

array An associative array of arbitrary hook data keyed by hook name.

File

core/tests/Drupal/KernelTests/Core/Entity/EntityKernelTestBase.php, line 136

Class

EntityKernelTestBase
Defines an abstract test base for entity kernel tests.

Namespace

Drupal\KernelTests\Core\Entity

Code

protected function getHooksInfo() {
  $key = 'entity_test.hooks';
  $hooks = $this->state
    ->get($key);
  $this->state
    ->set($key, []);
  return $hooks;
}