function EntityUnitTestBase::getHooksInfo

Returns the entity_test hook invocation info.

Return value

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

File

core/modules/system/src/Tests/Entity/EntityUnitTestBase.php, line 150

Class

EntityUnitTestBase
Defines an abstract test base for entity unit tests.

Namespace

Drupal\system\Tests\Entity

Code

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

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