Mercurial > hg > isophonics-drupal-site
comparison core/modules/toolbar/tests/src/Functional/ToolbarCacheContextsTest.php @ 14:1fec387a4317
Update Drupal core to 8.5.2 via Composer
author | Chris Cannam |
---|---|
date | Mon, 23 Apr 2018 09:46:53 +0100 |
parents | 4c8ae668cc8c |
children |
comparison
equal
deleted
inserted
replaced
13:5fb285c0d0e3 | 14:1fec387a4317 |
---|---|
54 protected function setUp() { | 54 protected function setUp() { |
55 parent::setUp(); | 55 parent::setUp(); |
56 | 56 |
57 $this->adminUser = $this->drupalCreateUser($this->perms); | 57 $this->adminUser = $this->drupalCreateUser($this->perms); |
58 $this->adminUser2 = $this->drupalCreateUser($this->perms); | 58 $this->adminUser2 = $this->drupalCreateUser($this->perms); |
59 } | |
60 | |
61 /** | |
62 * Tests toolbar cache integration. | |
63 */ | |
64 public function testCacheIntegration() { | |
65 $this->installExtraModules(['dynamic_page_cache']); | |
66 $this->drupalLogin($this->adminUser); | |
67 $this->drupalGet('test-page'); | |
68 $this->assertSame('MISS', $this->getSession()->getResponseHeader('X-Drupal-Dynamic-Cache')); | |
69 $this->drupalGet('test-page'); | |
70 $this->assertSame('HIT', $this->getSession()->getResponseHeader('X-Drupal-Dynamic-Cache')); | |
59 } | 71 } |
60 | 72 |
61 /** | 73 /** |
62 * Tests toolbar cache contexts. | 74 * Tests toolbar cache contexts. |
63 */ | 75 */ |