You are here

public function RenderCacheIntegrationTest::testEntityBasedViewCacheTagsWithCachePluginNone in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/views/tests/src/Kernel/RenderCacheIntegrationTest.php \Drupal\Tests\views\Kernel\RenderCacheIntegrationTest::testEntityBasedViewCacheTagsWithCachePluginNone()

Tests an entity-based view's cache tags when using the "none" cache plugin.

File

core/modules/views/tests/src/Kernel/RenderCacheIntegrationTest.php, line 190

Class

RenderCacheIntegrationTest
Tests the general integration between views and the render cache.

Namespace

Drupal\Tests\views\Kernel

Code

public function testEntityBasedViewCacheTagsWithCachePluginNone() {
  $view = Views::getview('entity_test_row');
  $view
    ->getDisplay()
    ->overrideOption('cache', [
    'type' => 'none',
  ]);
  $view
    ->save();
  $this
    ->assertCacheTagsForEntityBasedView(FALSE);
}