From 323fa5272db8f70e543507e7aaa24e2a19e090ac Mon Sep 17 00:00:00 2001 From: Yoshiya Hinosawa Date: Tue, 25 May 2021 22:35:17 +0900 Subject: fix(extension/file): update File constructor following the spec (#10760) --- tools/wpt/testharnessreport.js | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'tools/wpt/testharnessreport.js') diff --git a/tools/wpt/testharnessreport.js b/tools/wpt/testharnessreport.js index d3e783376..b1852a488 100644 --- a/tools/wpt/testharnessreport.js +++ b/tools/wpt/testharnessreport.js @@ -13,3 +13,12 @@ window.add_result_callback(({ message, name, stack, status }) => { window.add_completion_callback((_tests, _harnessStatus) => { Deno.exit(0); }); + +globalThis.document = { + // document.body shim for FileAPI/file/File-constructor.any.html test + body: { + toString() { + return "[object HTMLBodyElement]"; + }, + }, +}; -- cgit v1.2.3