function RenderCacheIntegrationTest::testFieldBasedViewCacheTagsWithCachePluginNone

Same name and namespace in other branches
  1. 9 core/modules/views/tests/src/Kernel/RenderCacheIntegrationTest.php \Drupal\Tests\views\Kernel\RenderCacheIntegrationTest::testFieldBasedViewCacheTagsWithCachePluginNone()
  2. 10 core/modules/views/tests/src/Kernel/RenderCacheIntegrationTest.php \Drupal\Tests\views\Kernel\RenderCacheIntegrationTest::testFieldBasedViewCacheTagsWithCachePluginNone()
  3. 11.x core/modules/views/tests/src/Kernel/RenderCacheIntegrationTest.php \Drupal\Tests\views\Kernel\RenderCacheIntegrationTest::testFieldBasedViewCacheTagsWithCachePluginNone()

Tests a field-based view's cache tags when using the "none" cache plugin.

File

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

Class

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

Namespace

Drupal\Tests\views\Kernel

Code

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

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