function BinaryFileResponseTest::providerTestCalculatedContentType
Same name in other branches
- 11.x core/tests/Drupal/KernelTests/Core/Http/BinaryFileResponseTest.php \Drupal\KernelTests\Core\Http\BinaryFileResponseTest::providerTestCalculatedContentType()
Data provider of file names and expected content-type values.
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Http/ BinaryFileResponseTest.php, line 40
Class
- BinaryFileResponseTest
- Tests the headers added by BinaryFileResponse.
Namespace
Drupal\KernelTests\Core\HttpCode
public static function providerTestCalculatedContentType() : array {
return [
[
'core/misc/print.css',
'text/css',
],
[
'core/misc/checkbox.js',
'text/javascript',
],
[
'core/misc/tree.png',
'image/png',
],
];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.