S3: get_object() now returns the AcceptRanges header (#6121)
This commit is contained in:
parent
e3244a9678
commit
ea96013957
@ -1364,6 +1364,7 @@ class S3Response(BaseResponse):
|
||||
|
||||
response_headers.update(key.metadata)
|
||||
response_headers.update(key.response_dict)
|
||||
response_headers.update({"AcceptRanges": "bytes"})
|
||||
return 200, response_headers, key.value
|
||||
|
||||
def _key_response_put(self, request, body, bucket_name, query, key_name):
|
||||
|
@ -73,6 +73,7 @@ def test_s3_server_bucket_create(key_name):
|
||||
res = test_client.get(f"/{key_name}", "http://foobaz.localhost:5000/")
|
||||
res.status_code.should.equal(200)
|
||||
res.data.should.equal(b"test value")
|
||||
assert res.headers.get("AcceptRanges") == "bytes"
|
||||
|
||||
|
||||
def test_s3_server_ignore_subdomain_for_bucketnames():
|
||||
|
Loading…
Reference in New Issue
Block a user