Merge "symlink: Ensure headers are returned as a list on py3"
This commit is contained in:
commit
15aff69606
@ -422,7 +422,7 @@ class SymlinkObjectContext(WSGIContext):
|
||||
resp = self._app_call(req.environ)
|
||||
response_header_dict = HeaderKeyDict(self._response_headers)
|
||||
symlink_sysmeta_to_usermeta(response_header_dict)
|
||||
self._response_headers = response_header_dict.items()
|
||||
self._response_headers = list(response_header_dict.items())
|
||||
return resp
|
||||
|
||||
def handle_get_head(self, req):
|
||||
|
@ -403,6 +403,7 @@ class TestSymlinkMiddleware(TestSymlinkMiddlewareBase):
|
||||
req = Request.blank('/v1/a/c/symlink?symlink=get', method='GET')
|
||||
status, headers, body = self.call_sym(req)
|
||||
self.assertEqual(status, '200 OK')
|
||||
self.assertIsInstance(headers, list)
|
||||
self.assertIn(('X-Symlink-Target', 'c1/o'), headers)
|
||||
self.assertNotIn('X-Symlink-Target-Account', dict(headers))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user