public function RendererLegacyTest::testHeaderAttributes in Drupal 8
Tests deprecation of the drupal_http_header_attributes() function.
@dataProvider providerAttributes
@expectedDeprecation drupal_http_header_attributes() is deprecated in Drupal 8.7.0 and will be removed before Drupal 9.0.0. Use \Drupal\Core\Render\HtmlResponseAttachmentsProcessor::formatHttpHeaderAttributes() instead. See https://www.drupal.org/node/3000051
File
- core/
tests/ Drupal/ KernelTests/ Core/ Render/ RendererLegacyTest.php, line 23
Class
- RendererLegacyTest
- Deprecation tests cases for the render layer.
Namespace
Drupal\KernelTests\Core\RenderCode
public function testHeaderAttributes($expected, $attributes) {
$this
->assertSame($expected, drupal_http_header_attributes($attributes));
$this
->assertSame($expected, HtmlResponseAttachmentsProcessor::formatHttpHeaderAttributes($attributes));
}