Commit 6b7acf7d authored by alexpott's avatar alexpott

Issue #2838954 by damiankloip: Ignore 'Transfer-Encoding' header in EntityResourceTestBase::testGet

parent 229d3816
......@@ -383,8 +383,11 @@ public function testGet() {
$get_headers = $response->getHeaders();
// Verify that the GET and HEAD responses are the same. The only difference
// is that there's no body.
$ignored_headers = ['Date', 'Content-Length', 'X-Drupal-Cache', 'X-Drupal-Dynamic-Cache'];
// is that there's no body. For this reason the 'Transfer-Encoding' header
// is also added to the list of headers to ignore, as this could be added to
// GET requests - depending on web server configuration. This would usually
// be 'Transfer-Encoding: chunked'.
$ignored_headers = ['Date', 'Content-Length', 'X-Drupal-Cache', 'X-Drupal-Dynamic-Cache', 'Transfer-Encoding'];
foreach ($ignored_headers as $ignored_header) {
unset($head_headers[$ignored_header]);
unset($get_headers[$ignored_header]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment