function PageCacheTest::testPageCache

Same name in other branches
  1. 9 core/modules/page_cache/tests/src/Functional/PageCacheTest.php \Drupal\Tests\page_cache\Functional\PageCacheTest::testPageCache()
  2. 8.9.x core/modules/page_cache/tests/src/Functional/PageCacheTest.php \Drupal\Tests\page_cache\Functional\PageCacheTest::testPageCache()
  3. 11.x core/modules/page_cache/tests/src/Functional/PageCacheTest.php \Drupal\Tests\page_cache\Functional\PageCacheTest::testPageCache()

Tests page caching.

File

core/modules/page_cache/tests/src/Functional/PageCacheTest.php, line 223

Class

PageCacheTest
Enables the page cache and tests it with various HTTP requests.

Namespace

Drupal\Tests\page_cache\Functional

Code

public function testPageCache() : void {
    $this->testCacheableWithCustomCacheControl();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheAnonymous403404();
    \Drupal::service('cache.page')->deleteAll();
    $this->testCacheabilityOfRedirectResponses();
    \Drupal::service('cache.page')->deleteAll();
    $this->testNoUrlNormalization();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheHeaders();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheWithoutVaryCookie();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheTags();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheAnonymousRolePermissions();
    \Drupal::service('cache.page')->deleteAll();
    $this->testHead();
    \Drupal::service('cache.page')->deleteAll();
    $this->testPageCacheTagsIndependentFromCacheabilityHeaders();
}

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