protected function EntityTestTextItemNormalizerTest::getExpectedCacheContexts in Drupal 9
Same name and namespace in other branches
- 8 core/modules/system/tests/modules/entity_test/tests/src/Functional/Rest/EntityTestTextItemNormalizerTest.php \Drupal\Tests\entity_test\Functional\Rest\EntityTestTextItemNormalizerTest::getExpectedCacheContexts()
- 10 core/modules/system/tests/modules/entity_test/tests/src/Functional/Rest/EntityTestTextItemNormalizerTest.php \Drupal\Tests\entity_test\Functional\Rest\EntityTestTextItemNormalizerTest::getExpectedCacheContexts()
The expected cache contexts for the GET/HEAD response of the test entity.
Return value
string[]
Overrides EntityResourceTestBase::getExpectedCacheContexts
See also
::testGet
File
- core/
modules/ system/ tests/ modules/ entity_test/ tests/ src/ Functional/ Rest/ EntityTestTextItemNormalizerTest.php, line 138
Class
- EntityTestTextItemNormalizerTest
- @group rest
Namespace
Drupal\Tests\entity_test\Functional\RestCode
protected function getExpectedCacheContexts() {
return Cache::mergeContexts([
// The cache context set by the filter_test_cache_contexts filter.
'languages:' . LanguageInterface::TYPE_CONTENT,
// The default cache contexts for Renderer.
'languages:' . LanguageInterface::TYPE_INTERFACE,
'theme',
// The cache tags set by the filter_test_cache_merge filter.
'user.permissions',
], parent::getExpectedCacheContexts());
}