| Index: LayoutTests/http/tests/fetch/script-tests/response.js
|
| diff --git a/LayoutTests/http/tests/fetch/script-tests/response.js b/LayoutTests/http/tests/fetch/script-tests/response.js
|
| index e073efa7de9457cdf90f88702b57a1ac35ad9897..3bb470065df4ccc0ea9bffad9e0eace2fb07798d 100644
|
| --- a/LayoutTests/http/tests/fetch/script-tests/response.js
|
| +++ b/LayoutTests/http/tests/fetch/script-tests/response.js
|
| @@ -346,10 +346,18 @@ promise_test(function(t) {
|
| }, 'MIME type for Blob');
|
|
|
| promise_test(function(t) {
|
| - var res = new Response(new Blob([''], {type: 'Text/Plain'}));
|
| + var res = new Response(new Blob(['hello'], {type: 'Text/Plain'}));
|
| return res.blob()
|
| .then(function(blob) {
|
| assert_equals(blob.type, 'text/plain');
|
| + assert_equals(blob.size, 5);
|
| + assert_equals(res.headers.get('Content-Type'), 'text/plain');
|
| + return res.blob();
|
| + }).then(function(blob) {
|
| + // When we read from a response twice, it returns an empty contents.
|
| + // But the type should remain.
|
| + assert_equals(blob.type, 'text/plain');
|
| + assert_equals(blob.size, 0);
|
| assert_equals(res.headers.get('Content-Type'), 'text/plain');
|
| });
|
| }, 'MIME type for Blob with non-empty type');
|
|
|