You are here

protected function WebformAssertLegacyTrait::assertNoCacheTag in Webform 6.x

Same name and namespace in other branches
  1. 8.5 tests/src/Traits/WebformAssertLegacyTrait.php \Drupal\Tests\webform\Traits\WebformAssertLegacyTrait::assertNoCacheTag()

Asserts whether an expected cache tag was absent in the last response.

Parameters

string $cache_tag: The cache tag to check.

See also

https://www.drupal.org/node/2864029

File

tests/src/Traits/WebformAssertLegacyTrait.php, line 656

Class

WebformAssertLegacyTrait
Provides convenience methods for assertions in browser tests.

Namespace

Drupal\Tests\webform\Traits

Code

protected function assertNoCacheTag($cache_tag) {
  $this
    ->assertSession()
    ->responseHeaderNotContains('X-Drupal-Cache-Tags', $cache_tag);
}