You are here

protected function CacheTest::assertCacheInvalidation in Apigee Edge 8

Check to see if the cache is invalidated.

Parameters

array $keys: Cache keys to check.

callable $action: Callable action that triggers invalidation.

bool $exists_before: TRUE if the cache keys exist before the function call.

bool $exists_after: FALSE if the cache keys should be removed after the function call.

3 calls to CacheTest::assertCacheInvalidation()
CacheTest::developerDeletedTest in tests/src/FunctionalJavascript/CacheTest.php
Tests developer & developer app cache invalidation after developer removal.
CacheTest::userDeletedTest in tests/src/FunctionalJavascript/CacheTest.php
Tests developer and developer app cache invalidation after user removal.
CacheTest::userUpdatedTest in tests/src/FunctionalJavascript/CacheTest.php
Tests developer cache invalidation after editing user.

File

tests/src/FunctionalJavascript/CacheTest.php, line 305

Class

CacheTest
Apigee Edge entity cache related tests.

Namespace

Drupal\Tests\apigee_edge\FunctionalJavascript

Code

protected function assertCacheInvalidation(array $keys, callable $action, bool $exists_before = TRUE, bool $exists_after = FALSE) {
  $this
    ->assertKeys($keys, $exists_before);
  $action();
  $this
    ->assertKeys($keys, $exists_after);
}