mirror of
https://github.com/servo/servo.git
synced 2025-08-09 07:25:35 +01:00
Update web-platform-tests to revision b'7af9d6ec48ab04043a2bea85a3599904a1a19efa'
This commit is contained in:
parent
8050c95e31
commit
87be1008de
2742 changed files with 142451 additions and 40667 deletions
|
@ -117,14 +117,12 @@ directory_test(async (t, root) => {
|
|||
const handle = await createEmptyFile(t, 'bad_offset', root);
|
||||
const stream = await handle.createWritable();
|
||||
|
||||
await promise_rejects_dom(
|
||||
t, 'InvalidStateError', stream.write({type: 'write', position: 4, data: new Blob(['abc'])}));
|
||||
await promise_rejects_js(
|
||||
t, TypeError, stream.close(), 'stream is already closed');
|
||||
await stream.write({type: 'write', position: 4, data: new Blob(['abc'])});
|
||||
await stream.close();
|
||||
|
||||
assert_equals(await getFileContents(handle), '');
|
||||
assert_equals(await getFileSize(handle), 0);
|
||||
}, 'write() called with an invalid offset');
|
||||
assert_equals(await getFileContents(handle), '\0\0\0\0abc');
|
||||
assert_equals(await getFileSize(handle), 7);
|
||||
}, 'write() called with an offset beyond the end of the file');
|
||||
|
||||
directory_test(async (t, root) => {
|
||||
const handle = await createEmptyFile(t, 'empty_string', root);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue