<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[281769] trunk/LayoutTests/imported/w3c</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/281769">281769</a></dd>
<dt>Author</dt> <dd>sihui_liu@apple.com</dd>
<dt>Date</dt> <dd>2021-08-30 11:22:32 -0700 (Mon, 30 Aug 2021)</dd>
</dl>

<h3>Log Message</h3>
<pre>Import file-system-access tests from WPT
https://bugs.webkit.org/show_bug.cgi?id=229593

Reviewed by Ryosuke Niwa.

* resources/import-expectations.json:
* web-platform-tests/file-system-access/META.yml: Added.
* web-platform-tests/file-system-access/README.md: Added.
* web-platform-tests/file-system-access/idlharness.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/idlharness.https.any.html: Added.
* web-platform-tests/file-system-access/idlharness.https.any.js: Added.
* web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/idlharness.https.any.worker.html: Added.
* web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/opaque-origin.https.window.html: Added.
* web-platform-tests/file-system-access/opaque-origin.https.window.js: Added.
(add_iframe):
(async verify_does_not_exist_in_data_uri_iframe):
(async verify_results_from_sandboxed_child_window):
* web-platform-tests/file-system-access/resources/data/testfile.txt: Added.
* web-platform-tests/file-system-access/resources/data/w3c-import.log: Added.
* web-platform-tests/file-system-access/resources/local-fs-test-helpers.js: Added.
(const.directory_promise.async await):
(const.directory_promise):
(directory_test):
(async directory_test):
* web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js: Added.
* web-platform-tests/file-system-access/resources/message-target-service-worker.js: Added.
* web-platform-tests/file-system-access/resources/message-target-shared-worker.js: Added.
* web-platform-tests/file-system-access/resources/message-target.html: Added.
* web-platform-tests/file-system-access/resources/message-target.js: Added.
(async receiver):
(add_message_event_handlers):
* web-platform-tests/file-system-access/resources/messaging-blob-helpers.js: Added.
(async create_message_target_blob_url):
(async create_message_target_data_uri):
(async create_message_target_html_without_subresources):
(async fetch_text):
* web-platform-tests/file-system-access/resources/messaging-helpers.js: Added.
(create_dedicated_worker):
(async create_service_worker):
(async add_iframe):
(async open_window):
(async wait_for_loaded_message):
(create_message_channel):
(async create_file_system_handles):
(async do_post_message_test):
(async do_message_port_test):
* web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js: Added.
(async serialize_handles):
(async serialize_handle):
(async serialize_file_system_handle):
(async serialize_file_system_file_handle):
(async serialize_file_system_directory_handle):
(async assert_equals_cloned_handles):
(assert_equals_serialized_handles):
(assert_equals_serialized_handle):
(assert_equals_serialized_file_system_handle):
(assert_equals_serialized_file_system_file_handle):
(assert_equals_serialized_file_system_directory_handle):
(serialize_message_error_event):
(assert_equals_serialized_message_error_event):
* web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html: Added.
* web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js: Added.
(async cleanupSandboxedFileSystem):
* web-platform-tests/file-system-access/resources/sync-access-handle-test.js: Added.
(async cleanupSandboxedFileSystem):
* web-platform-tests/file-system-access/resources/test-helpers.js: Added.
(navigator.userAgent.includes):
(async getFileSize):
(async getFileContents):
(async getDirectoryEntryCount):
(async getSortedDirectoryEntries):
(async createFileWithContents):
(garbageCollect):
* web-platform-tests/file-system-access/resources/w3c-import.log: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js: Added.
(promise_test.async t):
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js: Added.
(sync_access_handle_test.async testCase):
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js: Added.
(sync_access_handle_test.async t):
(sync_access_handle_test.async testCase):
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js: Added.
(sync_access_handle_test.async testCase):
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js: Added.
(sync_access_handle_test):
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js: Added.
(sync_access_handle_test.async testCase):
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt: Added.
* web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html: Added.
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js: Added.
(async create_broadcast_channel):
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js: Added.
(async do_send_message_error_test):
(async do_receive_message_error_test):
(async do_send_and_receive_message_error_test):
(async do_send_message_port_error_test):
(async do_receive_message_port_error_test):
(async do_send_and_receive_message_port_error_test):
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js: Added.
(directory_test.async t):
(self.SharedWorker.undefined.directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js: Added.
(directory_test.async t):
(self.SharedWorker.undefined.directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js: Added.
(sync_access_handle_test.async handle):
* web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js: Added.
(directory_test.async t):
* web-platform-tests/file-system-access/script-tests/w3c-import.log: Added.
* web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt: Added.
* web-platform-tests/file-system-access/showPicker-errors.https.window.html: Added.
* web-platform-tests/file-system-access/showPicker-errors.https.window.js: Added.
(promise_test.async t):
(define_file_picker_error_tests.async promise_test):
(define_file_picker_error_tests.async const):
(define_file_picker_error_tests):
(define_file_picker_extension_error_test):
* web-platform-tests/file-system-access/w3c-import.log: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsimportedw3cChangeLog">trunk/LayoutTests/imported/w3c/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsimportedw3cresourcesimportexpectationsjson">trunk/LayoutTests/imported/w3c/resources/import-expectations.json</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li>trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/</li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessMETAyml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/META.yml</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessREADMEmd">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/README.md</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.js</a></li>
<li>trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/</li>
<li>trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/</li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesdatatestfiletxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/testfile.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesdataw3cimportlog">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/w3c-import.log</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourceslocalfstesthelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/local-fs-test-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetdedicatedworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetserviceworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-service-worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetsharedworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-shared-worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargethtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagingblobhelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-blob-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessaginghelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagingserializehelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesopaqueoriginsandboxhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcessandboxedfstesthelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcessyncaccesshandletestjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sync-access-handle-test.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcestesthelpersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/test-helpers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesw3cimportlog">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/w3c-import.log</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyworkerhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html</a></li>
<li>trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/</li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleIndexedDBjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleisSameEntryjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageBroadcastChanneljs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageErrorjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortframesjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortwindowsjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortworkersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageframesjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessagewindowsjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageworkersjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleremovejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandlegetDirectoryHandlejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandlegetFileHandlejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleiterationjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleremoveEntryjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleresolvejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemFileHandlecreatesyncaccesshandlededicatedworkerjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemFileHandlegetFilejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemSyncAccessHandleflushjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreampipedjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreamwritejs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreamjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsw3cimportlog">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/w3c-import.log</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowhtml">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.html</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowjs">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessw3cimportlog">trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/w3c-import.log</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsimportedw3cChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/imported/w3c/ChangeLog (281768 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/ChangeLog 2021-08-30 17:43:49 UTC (rev 281768)
+++ trunk/LayoutTests/imported/w3c/ChangeLog    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -1,3 +1,257 @@
</span><ins>+2021-08-30  Sihui Liu  <sihui_liu@apple.com>
+
+        Import file-system-access tests from WPT
+        https://bugs.webkit.org/show_bug.cgi?id=229593
+
+        Reviewed by Ryosuke Niwa.
+
+        * resources/import-expectations.json:
+        * web-platform-tests/file-system-access/META.yml: Added.
+        * web-platform-tests/file-system-access/README.md: Added.
+        * web-platform-tests/file-system-access/idlharness.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/idlharness.https.any.html: Added.
+        * web-platform-tests/file-system-access/idlharness.https.any.js: Added.
+        * web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/idlharness.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/opaque-origin.https.window.html: Added.
+        * web-platform-tests/file-system-access/opaque-origin.https.window.js: Added.
+        (add_iframe):
+        (async verify_does_not_exist_in_data_uri_iframe):
+        (async verify_results_from_sandboxed_child_window):
+        * web-platform-tests/file-system-access/resources/data/testfile.txt: Added.
+        * web-platform-tests/file-system-access/resources/data/w3c-import.log: Added.
+        * web-platform-tests/file-system-access/resources/local-fs-test-helpers.js: Added.
+        (const.directory_promise.async await):
+        (const.directory_promise):
+        (directory_test):
+        (async directory_test):
+        * web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js: Added.
+        * web-platform-tests/file-system-access/resources/message-target-service-worker.js: Added.
+        * web-platform-tests/file-system-access/resources/message-target-shared-worker.js: Added.
+        * web-platform-tests/file-system-access/resources/message-target.html: Added.
+        * web-platform-tests/file-system-access/resources/message-target.js: Added.
+        (async receiver):
+        (add_message_event_handlers):
+        * web-platform-tests/file-system-access/resources/messaging-blob-helpers.js: Added.
+        (async create_message_target_blob_url):
+        (async create_message_target_data_uri):
+        (async create_message_target_html_without_subresources):
+        (async fetch_text):
+        * web-platform-tests/file-system-access/resources/messaging-helpers.js: Added.
+        (create_dedicated_worker):
+        (async create_service_worker):
+        (async add_iframe):
+        (async open_window):
+        (async wait_for_loaded_message):
+        (create_message_channel):
+        (async create_file_system_handles):
+        (async do_post_message_test):
+        (async do_message_port_test):
+        * web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js: Added.
+        (async serialize_handles):
+        (async serialize_handle):
+        (async serialize_file_system_handle):
+        (async serialize_file_system_file_handle):
+        (async serialize_file_system_directory_handle):
+        (async assert_equals_cloned_handles):
+        (assert_equals_serialized_handles):
+        (assert_equals_serialized_handle):
+        (assert_equals_serialized_file_system_handle):
+        (assert_equals_serialized_file_system_file_handle):
+        (assert_equals_serialized_file_system_directory_handle):
+        (serialize_message_error_event):
+        (assert_equals_serialized_message_error_event):
+        * web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html: Added.
+        * web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js: Added.
+        (async cleanupSandboxedFileSystem):
+        * web-platform-tests/file-system-access/resources/sync-access-handle-test.js: Added.
+        (async cleanupSandboxedFileSystem):
+        * web-platform-tests/file-system-access/resources/test-helpers.js: Added.
+        (navigator.userAgent.includes):
+        (async getFileSize):
+        (async getFileContents):
+        (async getDirectoryEntryCount):
+        (async getSortedDirectoryEntries):
+        (async createFileWithContents):
+        (garbageCollect):
+        * web-platform-tests/file-system-access/resources/w3c-import.log: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js: Added.
+        (promise_test.async t):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js: Added.
+        (sync_access_handle_test.async testCase):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js: Added.
+        (sync_access_handle_test.async t):
+        (sync_access_handle_test.async testCase):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js: Added.
+        (sync_access_handle_test.async testCase):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js: Added.
+        (sync_access_handle_test):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js: Added.
+        (sync_access_handle_test.async testCase):
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt: Added.
+        * web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html: Added.
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js: Added.
+        (async create_broadcast_channel):
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js: Added.
+        (async do_send_message_error_test):
+        (async do_receive_message_error_test):
+        (async do_send_and_receive_message_error_test):
+        (async do_send_message_port_error_test):
+        (async do_receive_message_port_error_test):
+        (async do_send_and_receive_message_port_error_test):
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js: Added.
+        (directory_test.async t):
+        (self.SharedWorker.undefined.directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js: Added.
+        (directory_test.async t):
+        (self.SharedWorker.undefined.directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js: Added.
+        (sync_access_handle_test.async handle):
+        * web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js: Added.
+        (directory_test.async t):
+        * web-platform-tests/file-system-access/script-tests/w3c-import.log: Added.
+        * web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt: Added.
+        * web-platform-tests/file-system-access/showPicker-errors.https.window.html: Added.
+        * web-platform-tests/file-system-access/showPicker-errors.https.window.js: Added.
+        (promise_test.async t):
+        (define_file_picker_error_tests.async promise_test):
+        (define_file_picker_error_tests.async const):
+        (define_file_picker_error_tests):
+        (define_file_picker_extension_error_test):
+        * web-platform-tests/file-system-access/w3c-import.log: Added.
+
</ins><span class="cx"> 2021-08-30  Chris Dumez  <cdumez@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Implement self.reportError()
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cresourcesimportexpectationsjson"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/imported/w3c/resources/import-expectations.json (281768 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/resources/import-expectations.json        2021-08-30 17:43:49 UTC (rev 281768)
+++ trunk/LayoutTests/imported/w3c/resources/import-expectations.json   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -219,6 +219,7 @@
</span><span class="cx">     "web-platform-tests/fetch/origin": "import", 
</span><span class="cx">     "web-platform-tests/fetch/range": "import", 
</span><span class="cx">     "web-platform-tests/fetch/stale-while-revalidate": "import", 
</span><ins>+    "web-platform-tests/file-system-access": "import", 
</ins><span class="cx">     "web-platform-tests/fullscreen": "skip", 
</span><span class="cx">     "web-platform-tests/gamepad": "skip", 
</span><span class="cx">     "web-platform-tests/generic-sensor": "skip", 
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessMETAyml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/META.yml (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/META.yml                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/META.yml       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+spec: https://wicg.github.io/file-system-access/
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessREADMEmd"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/README.md (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/README.md                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/README.md      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,2 @@
</span><ins>+This directory contains tests for the
+[File System Access](https://wicg.github.io/file-system-access/) specification.
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any-expected.txt                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any-expected.txt      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,61 @@
</span><ins>+
+PASS idl_test setup
+PASS idl_test validation
+PASS Partial interface Window: original interface defined
+PASS Partial interface Window: member names are unique
+PASS Partial interface DataTransferItem: original interface defined
+PASS Partial interface DataTransferItem: member names are unique
+PASS Partial interface StorageManager: original interface defined
+PASS Partial interface StorageManager: member names are unique
+PASS Partial interface Window[2]: member names are unique
+PASS Window includes GlobalEventHandlers: member names are unique
+PASS Window includes WindowEventHandlers: member names are unique
+PASS Window includes WindowOrWorkerGlobalScope: member names are unique
+PASS Window includes AnimationFrameProvider: member names are unique
+PASS Window includes WindowSessionStorage: member names are unique
+PASS Window includes WindowLocalStorage: member names are unique
+FAIL FileSystemHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface object length assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface object name assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: attribute kind assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: attribute name assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation isSameEntry(FileSystemHandle) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation queryPermission(optional FileSystemHandlePermissionDescriptor) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation requestPermission(optional FileSystemHandlePermissionDescriptor) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface object length assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface object name assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: operation getFile() assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: operation createWritable(optional FileSystemCreateWritableOptions) assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface object length assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface object name assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: async iterable<USVString, FileSystemHandle> undefined is not an object (evaluating 'this.get_interface_object().prototype')
+FAIL FileSystemDirectoryHandle interface: operation getFileHandle(USVString, optional FileSystemGetFileOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation getDirectoryHandle(USVString, optional FileSystemGetDirectoryOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation removeEntry(USVString, optional FileSystemRemoveOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation resolve(FileSystemHandle) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface object length assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface object name assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation write(FileSystemWriteChunkType) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation seek(unsigned long long) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation truncate(unsigned long long) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL StorageManager interface: operation getDirectory() assert_own_property: self does not have own property "StorageManager" expected property "StorageManager" missing
+FAIL DataTransferItem interface: operation getAsFileSystemHandle() assert_own_property: interface prototype object missing non-static operation expected property "getAsFileSystemHandle" missing
+FAIL Window interface: operation showOpenFilePicker(optional OpenFilePickerOptions) assert_own_property: global object missing non-static operation expected property "showOpenFilePicker" missing
+FAIL Window interface: operation showSaveFilePicker(optional SaveFilePickerOptions) assert_own_property: global object missing non-static operation expected property "showSaveFilePicker" missing
+FAIL Window interface: operation showDirectoryPicker(optional DirectoryPickerOptions) assert_own_property: global object missing non-static operation expected property "showDirectoryPicker" missing
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.html                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.html      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,16 @@
</span><ins>+// META: script=/resources/WebIDLParser.js
+// META: script=/resources/idlharness.js
+// META: timeout=long
+
+'use strict';
+
+idl_test(
+  ['file-system-access'],
+  ['storage', 'permissions', 'streams', 'html', 'dom'],
+  idl_array => {
+    idl_array.add_objects({
+      // TODO: Add instances of FileSystemHandle, FileSystemFileHandle,
+      // FileSystemDirectoryHandle and FileSystemWriter.
+    });
+  }
+);
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,57 @@
</span><ins>+
+PASS idl_test setup
+PASS idl_test validation
+PASS Partial interface Window: original interface defined
+PASS Partial interface Window: member names are unique
+PASS Partial interface DataTransferItem: original interface defined
+PASS Partial interface DataTransferItem: member names are unique
+PASS Partial interface StorageManager: original interface defined
+PASS Partial interface StorageManager: member names are unique
+PASS Partial interface Window[2]: member names are unique
+PASS Window includes GlobalEventHandlers: member names are unique
+PASS Window includes WindowEventHandlers: member names are unique
+PASS Window includes WindowOrWorkerGlobalScope: member names are unique
+PASS Window includes AnimationFrameProvider: member names are unique
+PASS Window includes WindowSessionStorage: member names are unique
+PASS Window includes WindowLocalStorage: member names are unique
+FAIL FileSystemHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface object length assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface object name assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: attribute kind assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: attribute name assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation isSameEntry(FileSystemHandle) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation queryPermission(optional FileSystemHandlePermissionDescriptor) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemHandle interface: operation requestPermission(optional FileSystemHandlePermissionDescriptor) assert_own_property: self does not have own property "FileSystemHandle" expected property "FileSystemHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface object length assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface object name assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: operation getFile() assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemFileHandle interface: operation createWritable(optional FileSystemCreateWritableOptions) assert_own_property: self does not have own property "FileSystemFileHandle" expected property "FileSystemFileHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface object length assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface object name assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: async iterable<USVString, FileSystemHandle> undefined is not an object (evaluating 'this.get_interface_object().prototype')
+FAIL FileSystemDirectoryHandle interface: operation getFileHandle(USVString, optional FileSystemGetFileOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation getDirectoryHandle(USVString, optional FileSystemGetDirectoryOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation removeEntry(USVString, optional FileSystemRemoveOptions) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemDirectoryHandle interface: operation resolve(FileSystemHandle) assert_own_property: self does not have own property "FileSystemDirectoryHandle" expected property "FileSystemDirectoryHandle" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface object assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface object length assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface object name assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation write(FileSystemWriteChunkType) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation seek(unsigned long long) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL FileSystemWritableFileStream interface: operation truncate(unsigned long long) assert_own_property: self does not have own property "FileSystemWritableFileStream" expected property "FileSystemWritableFileStream" missing
+FAIL StorageManager interface: operation getDirectory() assert_own_property: self does not have own property "StorageManager" expected property "StorageManager" missing
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessidlharnesshttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.worker.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window-expected.txt        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+PASS showDirectoryPicker() must be undefined for data URI iframes.
+PASS FileSystemDirectoryHandle must be undefined for data URI iframes.
+FAIL navigator.storage.getDirectory() and showDirectoryPicker() must reject in a sandboxed iframe. assert_equals: expected "showDirectoryPicker(): REJECTED: SecurityError" but got "showDirectoryPicker(): EXCEPTION: TypeError"
+FAIL navigator.storage.getDirectory() and showDirectoryPicker() must reject in a sandboxed opened window. assert_equals: expected "showDirectoryPicker(): REJECTED: SecurityError" but got "navigator.storage.getDirectory(): EXCEPTION: TypeError"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.html                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.html        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessopaqueoriginhttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.js                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.js  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,86 @@
</span><ins>+'use strict';
+
+const kSandboxWindowUrl = 'resources/opaque-origin-sandbox.html';
+
+function add_iframe(test, src, sandbox) {
+  const iframe = document.createElement('iframe');
+  iframe.src = src;
+  if (sandbox !== undefined) {
+    iframe.sandbox = sandbox;
+  }
+  document.body.appendChild(iframe);
+  test.add_cleanup(() => {
+    iframe.remove();
+  });
+}
+
+// Creates a data URI iframe that uses postMessage() to provide its parent
+// with the test result. The iframe checks for the existence of
+// |property_name| on the window.
+async function verify_does_not_exist_in_data_uri_iframe(
+  test, property_name) {
+  const iframe_content =
+    '<script>' +
+    '  const is_property_name_defined = ' +
+    `    (self.${property_name} !== undefined);` +
+    '  parent.postMessage({is_property_name_defined}, "*")' +
+    '</script>';
+
+  const data_uri = `data:text/html,${encodeURIComponent(iframe_content)}`;
+  add_iframe(test, data_uri);
+
+  const event_watcher = new EventWatcher(test, self, 'message');
+  const message_event = await event_watcher.wait_for('message')
+
+  assert_false(message_event.data.is_property_name_defined,
+    `Data URI iframes must not define '${property_name}'.`);
+}
+
+// |kSandboxWindowUrl| sends two messages to this window. The first is the
+// result of showDirectoryPicker(). The second is the result of
+// navigator.storage.getDirectory(). For windows using sandbox='allow-scripts',
+// both results must produce rejected promises.
+async function verify_results_from_sandboxed_child_window(test) {
+  const event_watcher = new EventWatcher(test, self, 'message');
+
+  const first_message_event = await event_watcher.wait_for('message');
+  assert_equals(
+      first_message_event.data,
+      'showDirectoryPicker(): REJECTED: SecurityError');
+
+  const second_message_event = await event_watcher.wait_for('message');
+  assert_equals(second_message_event.data,
+    'navigator.storage.getDirectory(): REJECTED: SecurityError');
+}
+
+promise_test(async test => {
+  await verify_does_not_exist_in_data_uri_iframe(test, 'showDirectoryPicker');
+}, 'showDirectoryPicker() must be undefined for data URI iframes.');
+
+promise_test(async test => {
+  await verify_does_not_exist_in_data_uri_iframe(
+    test, 'FileSystemDirectoryHandle');
+}, 'FileSystemDirectoryHandle must be undefined for data URI iframes.');
+
+promise_test(
+    async test => {
+      add_iframe(test, kSandboxWindowUrl, /*sandbox=*/ 'allow-scripts');
+      await verify_results_from_sandboxed_child_window(test);
+    },
+    'navigator.storage.getDirectory() and ' +
+        'showDirectoryPicker() must reject in a sandboxed iframe.');
+
+promise_test(
+    async test => {
+      const child_window_url = kSandboxWindowUrl +
+          '?pipe=header(Content-Security-Policy, sandbox allow-scripts)';
+
+      const child_window = window.open(child_window_url);
+      test.add_cleanup(() => {
+        child_window.close();
+      });
+
+      await verify_results_from_sandboxed_child_window(test);
+    },
+    'navigator.storage.getDirectory() and ' +
+        'showDirectoryPicker() must reject in a sandboxed opened window.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesdatatestfiletxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/testfile.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/testfile.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/testfile.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+Hello World!
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesdataw3cimportlog"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/w3c-import.log (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/w3c-import.log                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/w3c-import.log  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,17 @@
</span><ins>+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+       https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/data/testfile.txt
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourceslocalfstesthelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/local-fs-test-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/local-fs-test-helpers.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/local-fs-test-helpers.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,54 @@
</span><ins>+// This file defines a directory_test() function that can be used to define
+// tests that require a FileSystemDirectoryHandle. The implementation of that
+// function in this file will ask the user to select an empty directory and
+// uses that directory.
+//
+// Another implementation of this function exists in
+// sandboxed-fs-test-helpers.js, where that version uses the sandboxed file
+// system instead.
+
+const directory_promise = (async () => {
+  await new Promise(resolve => {
+    window.addEventListener('DOMContentLoaded', resolve);
+  });
+
+  // Small delay to give chrome's test automation a chance to actually install
+  // itself.
+  await new Promise(resolve => step_timeout(resolve, 100));
+
+  await window.test_driver.bless(
+      'show a file picker.<br />Please select an empty directory');
+  const entries = await self.showDirectoryPicker();
+  assert_true(entries instanceof FileSystemHandle);
+  assert_true(entries instanceof FileSystemDirectoryHandle);
+  for await (const entry of entries) {
+    assert_unreached('Selected directory is not empty');
+  }
+  return entries;
+})();
+
+function directory_test(func, description) {
+  promise_test(async t => {
+    const directory = await directory_promise;
+    // To be resilient against tests not cleaning up properly, cleanup before
+    // every test.
+    for await (let entry of directory.values()) {
+      await directory.removeEntry(
+          entry.name, {recursive: entry.kind === 'directory'});
+    }
+    await func(t, directory);
+  }, description);
+}
+
+directory_test(async (t, dir) => {
+  assert_equals(await dir.queryPermission({mode: 'read'}), 'granted');
+}, 'User succesfully selected an empty directory.');
+
+directory_test(async (t, dir) => {
+  const status = await dir.queryPermission({mode: 'readwrite'});
+  if (status == 'granted')
+    return;
+
+  await window.test_driver.bless('ask for write permission');
+  assert_equals(await dir.requestPermission({mode: 'readwrite'}), 'granted');
+}, 'User granted write access.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetdedicatedworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,9 @@
</span><ins>+'use strict';
+
+importScripts(
+  'test-helpers.js',
+  'messaging-serialize-helpers.js',
+  'message-target.js'
+);
+
+add_message_event_handlers(/*receiver=*/self, /*target=*/self);
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetserviceworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-service-worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-service-worker.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-service-worker.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,9 @@
</span><ins>+'use strict';
+
+importScripts(
+  'test-helpers.js',
+  'messaging-serialize-helpers.js',
+  'message-target.js'
+);
+
+add_message_event_handlers(/*receiver=*/self);
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetsharedworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-shared-worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-shared-worker.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-shared-worker.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,14 @@
</span><ins>+'use strict';
+
+importScripts(
+  'test-helpers.js',
+  'messaging-serialize-helpers.js',
+  'message-target.js'
+);
+
+self.addEventListener('connect', connect_event => {
+  const message_port = connect_event.ports[0];
+  add_message_event_handlers(
+    /*receiver=*/message_port, /*target=*/message_port);
+  message_port.start();
+});
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargethtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,22 @@
</span><ins>+<!DOCTYPE html>
+<script src='test-helpers.js'></script>
+<script src='messaging-serialize-helpers.js'></script>
+<script src='message-target.js'></script>
+<script id="inline_script">
+  'use strict'
+
+  if (window.parent !== null) {
+    window.parent.postMessage('LOADED', { targetOrigin: '*' });
+  }
+
+  if (window.opener !== null) {
+    window.opener.postMessage('LOADED', { targetOrigin: '*' });
+  }
+
+  // Use an undefined message target to send responses to
+  // MessageEvent::source instead.
+  const target = undefined;
+
+  add_message_event_handlers(
+    /*receiver=*/self, target, /*target_origin=*/'*');
+</script>
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagetargetjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,157 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+// add_message_event_handlers() is the helper function used to setup all
+// message targets, including iframes and workers.
+//
+// Adds a message event handler and a message error handler to |receiver|.
+// The 'data' property from received MessageEvents must include a 'type'
+// property. The 'type' selects the test logic to run. Most message type
+// handlers use postMessage() to respond to the sender with test results.
+// The sender then validates the test results after receiving the response.
+//
+// Both |target| and |target_origin| are optional. |target| is used
+// to send message responses back to the sender. When omitted, the
+// 'source' from received MessageEvents is used instead.
+//
+// For window messaging, |target_origin| specifies the origin to receive
+// responses. Most window tests use '*' for the |target_origin|. Worker
+// and message port tests must use undefined for |target_origin| to avoid
+// exceptions.
+function add_message_event_handlers(receiver, target, target_origin) {
+  receiver.addEventListener('message', async function (message_event) {
+    const message_data = message_event.data;
+
+    // Reply to the sender using the 'source' from the received MessageEvent.
+    let message_source = message_event.source;
+    if (message_source === null) {
+      // However, some message senders, like DedicatedWorkers, don't include
+      // a source. Fallback to the target when the source is null.
+      message_source = target;
+    }
+
+    try {
+      switch (message_data.type) {
+        case 'receive-message-port':
+          // Receive a MessagePort to use as a message target for testing.
+          add_message_event_handlers(
+            /*receiver=*/message_data.message_port,
+            /*target=*/message_data.message_port);
+          message_data.message_port.start();
+          break;
+
+        case 'create-broadcast-channel':
+          // Create a BroadcastChannel to use as a message target for testing.
+          const broadcast_channel =
+            new BroadcastChannel(message_data.broadcast_channel_name);
+          add_message_event_handlers(
+            /*receiver=*/broadcast_channel,
+            /*target=*/broadcast_channel);
+          message_source.postMessage(
+            { type: 'broadcast-channel-created' },
+            { targetOrigin: target_origin });
+          break;
+
+        case 'receive-file-system-handles':
+          // Receive a list of cloned FileSystemFileHandles. Access the
+          // properties of each FileSystemFileHandle by serializing the
+          // handle to a JavaScript object. Then respond with the serialized
+          // results, enabling the sender to verify that the cloned handle
+          // produced the expected property values from this execution context.
+          const serialized_handles = [];
+          const cloned_handles = message_data.cloned_handles;
+          for (let i = 0; i < cloned_handles.length; ++i) {
+            const serialized = await serialize_handle(cloned_handles[i]);
+            serialized_handles.push(serialized);
+          }
+          message_source.postMessage({
+            type: 'receive-serialized-file-system-handles',
+            serialized_handles,
+            // Respond with the cloned handles to create new clones for
+            // the sender to verify.
+            cloned_handles,
+          }, { targetOrigin: target_origin });
+          break;
+
+        case 'receive-serialized-file-system-handles':
+          // Do nothing. This message is meant for test runner validation.
+          // Other message targets may receive this message while testing
+          // broadcast channels.
+          break;
+
+        case 'create-file':
+          // Create a new file and then respond to the sender with it.
+          const directory = await navigator.storage.getDirectory();
+          const file_handle =
+            await directory.getFileHandle('temp-file', { create: true });
+          message_source.postMessage(
+            { type: 'receive-file', file_handle },
+            { targetOrigin: target_origin });
+          break;
+
+        case 'create-directory':
+          // Create a new directory and then respond to the sender with it.
+          const parent_directory = await navigator.storage.getDirectory();
+          const directory_handle =
+            await parent_directory.getDirectoryHandle('temp-directory',
+              { create: true });
+          message_source.postMessage(
+            { type: 'receive-directory', directory_handle },
+            { targetOrigin: target_origin });
+          break;
+
+        case 'create-sync-access-handle':
+          // Receive a file and create a sync access handle out of it. Report
+          // success to the sender.
+          let success = true;
+          try {
+            const access_handle = await message_data.file_handle.createSyncAccessHandle();
+            await access_handle.close();
+          } catch (error) {
+            success = false;
+          }
+
+          message_source.postMessage(
+            { type: 'receive-sync-access-handle-result', success },
+            { targetOrigin: target_origin });
+          break;
+
+        default:
+          throw `Unknown message type: '${message_data.type}'`;
+      }
+    } catch (error) {
+      // Respond with an error to trigger a failure in the sender's
+      // test runner.
+      message_source.postMessage(`ERROR: ${error}`,
+        { targetOrigin: target_origin });
+    }
+  });
+
+  receiver.addEventListener('messageerror', async function (message_event) {
+    // Select the target for message responses (see comment in 'message' event
+    // listener above).
+    let message_source = message_event.source;
+    if (message_source === null) {
+      message_source = target;
+    }
+
+    try {
+      // Respond with the MessageEvent's property values, enabling the sender
+      // to verify results.
+      const serialized_message_error_event =
+        serialize_message_error_event(message_event);
+      message_source.postMessage({
+        type: 'serialized-message-error',
+        serialized_message_error_event
+      }, { targetOrigin: target_origin });
+    } catch (error) {
+      // Respond with an error to trigger a failure in the sender's
+      // test runner.
+      message_source.postMessage(`ERROR: ${error}`,
+        { targetOrigin: target_origin });
+    }
+  });
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagingblobhelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-blob-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-blob-helpers.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-blob-helpers.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,51 @@
</span><ins>+'use strict';
+
+// Creates a blob URL with the contents of 'message-target.html'. Use the
+// blob as an iframe src or a window.open() URL, which creates a same origin
+// message target.
+async function create_message_target_blob_url(test) {
+  const html = await create_message_target_html_without_subresources(test);
+  const blob = new Blob([html], { type: 'text/html' });
+  return URL.createObjectURL(blob);
+}
+
+// Creates a data URI with the contents of 'message-target.html'. Use the
+// data URI as an iframe src, which creates a cross origin message target.
+async function create_message_target_data_uri(test) {
+  const iframe_html =
+    await create_message_target_html_without_subresources(test);
+  return `data:text/html,${encodeURIComponent(iframe_html)}`;
+}
+
+// Constructs a version of 'message-target.html' without any subresources.
+// Enables the creation of blob URLs, data URIs and iframe srcdocs re-using
+// the contents of 'message-target.html'.
+async function create_message_target_html_without_subresources(test) {
+  const test_helpers_script = await fetch_text('resources/test-helpers.js');
+
+  const messaging_helpers_script =
+    await fetch_text('resources/messaging-helpers.js');
+
+  const messaging_serialize_helpers_script =
+    await fetch_text('resources/messaging-serialize-helpers.js');
+
+  const message_target_script =
+    await fetch_text('resources/message-target.js');
+
+  // Get the inline script code from 'message-target.html'.
+  const iframe = await add_iframe(test, { src: 'resources/message-target.html' });
+  const iframe_script =
+    iframe.contentWindow.document.getElementById('inline_script').outerHTML;
+  iframe.remove();
+
+  return '<!DOCTYPE html>' +
+    `<script>${test_helpers_script}</script>` +
+    `<script>${messaging_serialize_helpers_script}</script>` +
+    `<script>${message_target_script}</script>` +
+    `${iframe_script}`;
+}
+
+async function fetch_text(url) {
+  const response = await fetch(url);
+  return await response.text();
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessaginghelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-helpers.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-helpers.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,187 @@
</span><ins>+'use strict';
+
+// This script depends on the following script:
+//    /file-system-access/resources/test-helpers.js
+//    /service-workers/service-worker/resources/test-helpers.sub.js
+
+// Define the URL constants used for each type of message target, including
+// iframes and workers.
+const kDocumentMessageTarget = 'resources/message-target.html';
+const kSharedWorkerMessageTarget = 'resources/message-target-shared-worker.js';
+const kServiceWorkerMessageTarget =
+  'resources/message-target-service-worker.js';
+const kDedicatedWorkerMessageTarget =
+  'resources/message-target-dedicated-worker.js';
+
+function create_dedicated_worker(test, url) {
+  const dedicated_worker = new Worker(url);
+  test.add_cleanup(() => {
+    dedicated_worker.terminate();
+  });
+  return dedicated_worker;
+}
+
+async function create_service_worker(test, script_url, scope) {
+  const registration = await service_worker_unregister_and_register(
+    test, script_url, scope);
+  test.add_cleanup(() => {
+    return registration.unregister();
+  });
+  return registration;
+}
+
+// Creates an iframe and waits to receive a message from the iframe.
+// Valid |options| include src, srcdoc and sandbox, which mirror the
+// corresponding iframe element properties.
+async function add_iframe(test, options) {
+  const iframe = document.createElement('iframe');
+
+  if (options.sandbox !== undefined) {
+    iframe.sandbox = options.sandbox;
+  }
+
+  if (options.src !== undefined) {
+    iframe.src = options.src;
+  }
+
+  if (options.srcdoc !== undefined) {
+    iframe.srcdoc = options.srcdoc;
+  }
+
+  document.body.appendChild(iframe);
+  test.add_cleanup(() => {
+    iframe.remove();
+  });
+
+  await wait_for_loaded_message(self);
+  return iframe;
+}
+
+// Creates a child window using window.open() and waits to receive a message
+// from the child window.
+async function open_window(test, url) {
+  const child_window = window.open(url);
+  test.add_cleanup(() => {
+    child_window.close();
+  });
+  await wait_for_loaded_message(self);
+  return child_window;
+}
+
+// Wait until |receiver| gets a message event with the data set to 'LOADED'.
+// The postMessage() tests use messaging instead of the loaded event because
+// cross-origin child windows from window.open() do not dispatch the loaded
+// event to the parent window.
+async function wait_for_loaded_message(receiver) {
+  const message_promise = new Promise((resolve, reject) => {
+    receiver.addEventListener('message', message_event => {
+      if (message_event.data === 'LOADED') {
+        resolve();
+      } else {
+        reject('The message target must receive a "LOADED" message response.');
+      }
+    });
+  });
+  await message_promise;
+}
+
+// Sets up a new message channel. Sends one port to |target| and then returns
+// the other port.
+function create_message_channel(target, target_origin) {
+  const message_channel = new MessageChannel();
+
+  const message_data =
+    { type: 'receive-message-port', message_port: message_channel.port2 };
+  target.postMessage(
+    message_data,
+    {
+      transfer: [message_channel.port2],
+      targetOrigin: target_origin
+    });
+  message_channel.port1.start();
+  return message_channel.port1;
+}
+
+// Creates a variety of different FileSystemFileHandles for testing.
+async function create_file_system_handles(test, root) {
+  // Create some files to use with postMessage().
+  const empty_file = await createEmptyFile(test, 'empty-file', root);
+  const first_file = await createFileWithContents(
+    test, 'first-file-with-contents', 'first-text-content', root);
+  const second_file = await createFileWithContents(
+    test, 'second-file-with-contents', 'second-text-content', root);
+
+  // Create an empty directory to use with postMessage().
+  const empty_directory = await createDirectory(test, 'empty-directory', root);
+
+  // Create a directory containing both files and subdirectories to use
+  // with postMessage().
+  const directory_with_files =
+    await createDirectory(test, 'directory-with-files', root);
+  await createFileWithContents(test, 'first-file-in-directory',
+    'first-directory-text-content', directory_with_files);
+  await createFileWithContents(test, 'second-file-in-directory',
+    'second-directory-text-content', directory_with_files);
+  const subdirectory =
+    await createDirectory(test, 'subdirectory', directory_with_files);
+  await createFileWithContents(test, 'first-file-in-subdirectory',
+    'first-subdirectory-text-content', subdirectory);
+
+  return [
+    empty_file,
+    first_file,
+    second_file,
+    // Include the same FileSystemFileHandle twice.
+    second_file,
+    empty_directory,
+    // Include the Same FileSystemDirectoryHandle object twice.
+    empty_directory,
+    directory_with_files
+  ];
+}
+
+// Tests sending an array of FileSystemHandles to |target| with postMessage().
+// The array includes both FileSystemFileHandles and FileSystemDirectoryHandles.
+// After receiving the message, |target| accesses all cloned handles by
+// serializing the properties of each handle to a JavaScript object.
+//
+// |target| then responds with the resulting array of serialized handles. The
+// response also includes the array of cloned handles, which creates more
+// clones. After receiving the response, this test runner verifies that both
+// the serialized handles and the cloned handles contain the expected properties.
+async function do_post_message_test(
+  test, root_dir, receiver, target, target_origin) {
+  // Create and send the handles to |target|.
+  const handles =
+    await create_file_system_handles(test, root_dir, target, target_origin);
+  target.postMessage(
+    { type: 'receive-file-system-handles', cloned_handles: handles },
+    { targetOrigin: target_origin });
+
+  // Wait for |target| to respond with results.
+  const event_watcher = new EventWatcher(test, receiver, 'message');
+  const message_event = await event_watcher.wait_for('message');
+  const response = message_event.data;
+
+  assert_equals(response.type, 'receive-serialized-file-system-handles',
+    'The test runner must receive a "serialized-file-system-handles" ' +
+    `message response. Actual response: ${response}`);
+
+  // Verify the results.
+  const expected_serialized_handles = await serialize_handles(handles);
+
+  assert_equals_serialized_handles(
+    response.serialized_handles, expected_serialized_handles);
+
+  await assert_equals_cloned_handles(response.cloned_handles, handles);
+}
+
+// Runs the same test as do_post_message_test(), but uses a MessagePort.
+// This test starts by establishing a message channel between the test runner
+// and |target|. Afterwards, the test sends FileSystemHandles through the
+// message port channel.
+async function do_message_port_test(test, root_dir, target, target_origin) {
+  const message_port = create_message_channel(target, target_origin);
+  await do_post_message_test(
+      test, root_dir, /*receiver=*/ message_port, /*target=*/ message_port);
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesmessagingserializehelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,230 @@
</span><ins>+'use strict';
+
+// This script depends on the following script:
+//    /file-system-access/resources/test-helpers.js
+
+// Serializes an array of FileSystemHandles where each element can be either a
+// FileSystemFileHandle or FileSystemDirectoryHandle.
+async function serialize_handles(handle_array) {
+  const serialized_handle_array = [];
+  for (let i = 0; i < handle_array.length; ++i) {
+    serialized_handle_array.push(await serialize_handle(handle_array[i]));
+  }
+  return serialized_handle_array;
+}
+
+// Serializes either a FileSystemFileHandle or FileSystemDirectoryHandle.
+async function serialize_handle(handle) {
+  switch (handle.kind) {
+    case 'directory':
+      return await serialize_file_system_directory_handle(handle);
+    case 'file':
+      return await serialize_file_system_file_handle(handle);
+    default:
+      throw 'Object is not a FileSystemFileHandle or ' +
+          `FileSystemDirectoryHandle ${handle}`;
+  }
+}
+
+// Creates a dictionary for a FileSystemHandle base, which contains
+// serialized properties shared by both FileSystemFileHandle and
+// FileSystemDirectoryHandle.
+async function serialize_file_system_handle(handle) {
+  const read_permission =
+    await handle.queryPermission({ mode: 'read' });
+
+  const write_permission =
+    await handle.queryPermission({ mode: 'readwrite' })
+
+  return {
+    kind: handle.kind,
+    name: handle.name,
+    read_permission,
+    write_permission
+  };
+}
+
+// Create a dictionary with each property value in FileSystemFileHandle.
+// Also, reads the contents of the file to include with the returned
+// dictionary.  Example output:
+// {
+//   kind: "file",
+//   name: "example-file-name"
+//   read_permission: "granted",
+//   write_permission: "granted",
+//   contents: "example-file-contents"
+// }
+async function serialize_file_system_file_handle(file_handle) {
+  const contents = await getFileContents(file_handle);
+
+  const serialized_file_system_handle =
+    await serialize_file_system_handle(file_handle);
+
+  return Object.assign(serialized_file_system_handle, { contents });
+}
+
+// Create a dictionary with each property value in FileSystemDirectoryHandle.
+// Example output:
+// {
+//   kind: "directory",
+//   name: "example-directory-name"
+//   read_permission: "granted",
+//   write_permission: "granted",
+//   files: [<first serialized file>, ...]
+//   directories: [<first serialized subdirectory>, ...]
+// }
+async function serialize_file_system_directory_handle(directory_handle) {
+  // Serialize the contents of the directory.
+  const serialized_files = [];
+  const serialized_directories = [];
+  for await (const child_handle of directory_handle.values()) {
+    const serialized_child_handle = await serialize_handle(child_handle);
+    if (child_handle.kind === "directory") {
+      serialized_directories.push(serialized_child_handle);
+    } else {
+      serialized_files.push(serialized_child_handle);
+    }
+  }
+
+  // Order the serialized contents of the directory by name.
+  serialized_files.sort((left, right) => {
+    return left.name.localeCompare(right.name);
+  });
+  serialized_directories.sort((left, right) => {
+    return left.name.localeCompare(right.name);
+  });
+
+  // Serialize the directory's common properties shared by all
+  // FileSystemHandles.
+  const serialized_file_system_handle =
+    await serialize_file_system_handle(directory_handle);
+
+  return Object.assign(
+    serialized_file_system_handle,
+    { files: serialized_files, directories: serialized_directories });
+}
+
+// Verifies |left_array| is a clone of |right_array| where each element
+// is a cloned FileSystemHandle with the same properties and contents.
+async function assert_equals_cloned_handles(left_array, right_array) {
+  assert_equals(left_array.length, right_array.length,
+    'Each array of FileSystemHandles must have the same length');
+
+  for (let i = 0; i < left_array.length; ++i) {
+    assert_not_equals(left_array[i], right_array[i],
+      'Clones must create new FileSystemHandle instances.');
+
+    const left_serialized = await serialize_handle(left_array[i]);
+    const right_serialized = await serialize_handle(right_array[i]);
+    assert_equals_serialized_handle(left_serialized, right_serialized);
+  }
+}
+
+// Verifies |left_array| is the same as |right_array| where each element
+// is a serialized FileSystemHandle with the same properties.
+function assert_equals_serialized_handles(left_array, right_array) {
+  assert_equals(left_array.length, right_array.length,
+    'Each array of serialized handles must have the same length');
+
+  for (let i = 0; i < left_array.length; ++i) {
+    assert_equals_serialized_handle(left_array[i], right_array[i]);
+  }
+}
+
+// Verifies each property of a serialized FileSystemFileHandle or
+// FileSystemDirectoryHandle.
+function assert_equals_serialized_handle(left, right) {
+  switch (left.kind) {
+    case 'directory':
+      assert_equals_serialized_file_system_directory_handle(left, right);
+      break;
+    case 'file':
+      assert_equals_serialized_file_system_file_handle(left, right);
+      break;
+    default:
+      throw 'Object is not a FileSystemFileHandle or ' +
+          `FileSystemDirectoryHandle ${left}`;
+  }
+}
+
+// Compares the output of serialize_file_system_handle() for
+// two FileSystemHandles.
+function assert_equals_serialized_file_system_handle(left, right) {
+  assert_equals(left.kind, right.kind,
+    'Each FileSystemHandle instance must use the expected "kind".');
+
+  assert_equals(left.name, right.name,
+    'Each FileSystemHandle instance must use the expected "name" ' +
+    ' property.');
+
+  assert_equals(left.read_permission, right.read_permission,
+    'Each FileSystemHandle instance must have the expected read ' +
+    ' permission.');
+
+  assert_equals(left.write_permission, right.write_permission,
+    'Each FileSystemHandle instance must have the expected write ' +
+    ' permission.');
+}
+
+// Compares the output of serialize_file_system_file_handle()
+// for two FileSystemFileHandle.
+function assert_equals_serialized_file_system_file_handle(left, right) {
+  assert_equals_serialized_file_system_handle(left, right);
+  assert_equals(left.contents, right.contents,
+    'Each FileSystemFileHandle instance must have the same contents.');
+}
+
+// Compares the output of serialize_file_system_directory_handle()
+// for two FileSystemDirectoryHandles.
+function assert_equals_serialized_file_system_directory_handle(left, right) {
+  assert_equals_serialized_file_system_handle(left, right);
+
+  assert_equals(left.files.length, right.files.length,
+    'Each FileSystemDirectoryHandle must contain the same number of ' +
+    'file children');
+
+  for (let i = 0; i < left.files.length; ++i) {
+    assert_equals_serialized_file_system_file_handle(
+      left.files[i], right.files[i]);
+  }
+
+  assert_equals(left.directories.length, right.directories.length,
+    'Each FileSystemDirectoryHandle must contain the same number of ' +
+    'directory children');
+
+  for (let i = 0; i < left.directories.length; ++i) {
+    assert_equals_serialized_file_system_directory_handle(
+      left.directories[i], right.directories[i]);
+  }
+}
+
+// Creates a dictionary with interesting property values from MessageEvent.
+function serialize_message_error_event(message_error_event) {
+  return {
+    data: message_error_event.data,
+    origin: message_error_event.origin,
+    last_event_id: message_error_event.lastEventId,
+    has_source: (message_error_event.source !== null),
+    ports_length: message_error_event.ports.length
+  };
+}
+
+// Compares the output of serialize_message_error_event() with an
+// expected result.
+function assert_equals_serialized_message_error_event(
+  serialized_event, expected_origin, expected_has_source) {
+  assert_equals(serialized_event.data, null,
+    'The message error event must set the "data" property to null.');
+
+  assert_equals(serialized_event.origin, expected_origin,
+    'The message error event must have the expected "origin" property.');
+
+  assert_equals(serialized_event.last_event_id, "",
+    'The message error event must set the "lastEventId" property to the empty string.');
+
+  assert_equals(serialized_event.has_source, expected_has_source,
+    'The message error event must have the expected "source" property.');
+
+  assert_equals(serialized_event.ports_length, 0,
+    'The message error event must not contain any message ports.');
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesopaqueoriginsandboxhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,39 @@
</span><ins>+<!DOCTYPE html>
+<script>
+  'use strict'
+
+  // Sends two messages to its creator:
+  // (1) The result of showDirectoryPicker().
+  // (2) The result of navigator.storage.getDirectory().
+
+  function post_message(data) {
+    if (window.parent !== null) {
+      window.parent.postMessage(data, { targetOrigin: '*' });
+    }
+    if (window.opener !== null) {
+      window.opener.postMessage(data, { targetOrigin: '*' });
+    }
+  }
+
+  try {
+    window.showDirectoryPicker()
+      .then(() => {
+        post_message('showDirectoryPicker(): FULFILLED');
+      }).catch(error => {
+        post_message(`showDirectoryPicker(): REJECTED: ${error.name}`);
+      });
+  } catch (error) {
+    post_message(`showDirectoryPicker(): EXCEPTION: ${error.name}`);
+  }
+
+  try {
+    navigator.storage.getDirectory()
+      .then(() => {
+        post_message('navigator.storage.getDirectory(): FULFILLED');
+      }).catch(error => {
+        post_message(`navigator.storage.getDirectory(): REJECTED: ${error.name}`);
+      });
+  } catch (error) {
+    post_message(`navigator.storage.getDirectory(): EXCEPTION: ${error.name}`);
+  }
+</script>
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcessandboxedfstesthelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,23 @@
</span><ins>+// This file defines a directory_test() function that can be used to define
+// tests that require a FileSystemDirectoryHandle. The implementation of that
+// function in this file will return an empty directory in the sandboxed file
+// system.
+//
+// Another implementation of this function exists in local-fs-test-helpers.js,
+// where that version uses the local file system instead.
+
+async function cleanupSandboxedFileSystem() {
+  const dir = await navigator.storage.getDirectory();
+  for await (let entry of dir.values())
+    await dir.removeEntry(entry.name, {recursive: entry.kind === 'directory'});
+}
+
+function directory_test(func, description) {
+  promise_test(async t => {
+    // To be extra resilient against bad tests, cleanup before every test.
+    await cleanupSandboxedFileSystem();
+
+    const dir = await navigator.storage.getDirectory();
+    await func(t, dir);
+  }, description);
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcessyncaccesshandletestjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sync-access-handle-test.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sync-access-handle-test.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sync-access-handle-test.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,17 @@
</span><ins>+async function cleanupSandboxedFileSystem() {
+  const dir = await navigator.storage.getDirectory();
+  for await (let entry of dir.values())
+    await dir.removeEntry(entry.name, {recursive: entry.kind === 'directory'});
+}
+
+function sync_access_handle_test(test, description) {
+  promise_test(async t => {
+    // To be extra resilient against bad tests, cleanup before every test.
+    await cleanupSandboxedFileSystem();
+    const dir = await navigator.storage.getDirectory();
+    const fileHandle = await dir.getFileHandle('OPFS.test', {create: true});
+    const syncHandle = await fileHandle.createSyncAccessHandle();
+    await test(t, syncHandle);
+    await syncHandle.close();
+  }, description);
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcestesthelpersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/test-helpers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/test-helpers.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/test-helpers.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,87 @@
</span><ins>+// A special path component meaning "this directory."
+const kCurrentDirectory = '.';
+
+// A special path component meaning "the parent directory."
+const kParentDirectory = '..';
+
+// Array of separators used to separate components in hierarchical paths.
+let kPathSeparators;
+if (navigator.userAgent.includes('Windows NT')) {
+  // Windows uses both '/' and '\' as path separators.
+  kPathSeparators = ['/', '\\'];
+} else {
+  kPathSeparators = ['/'];
+}
+
+async function getFileSize(handle) {
+  const file = await handle.getFile();
+  return file.size;
+}
+
+async function getFileContents(handle) {
+  const file = await handle.getFile();
+  return new Response(file).text();
+}
+
+async function getDirectoryEntryCount(handle) {
+  let result = 0;
+  for await (let entry of handle) {
+    result++;
+  }
+  return result;
+}
+
+async function getSortedDirectoryEntries(handle) {
+  let result = [];
+  for await (let entry of handle.values()) {
+    if (entry.kind === 'directory')
+      result.push(entry.name + '/');
+    else
+      result.push(entry.name);
+  }
+  result.sort();
+  return result;
+}
+
+async function createDirectory(test, name, parent) {
+  const new_dir_handle = await parent.getDirectoryHandle(name, {create: true});
+  test.add_cleanup(async () => {
+    try {
+      await parent.removeEntry(name, {recursive: true});
+    } catch (e) {
+      // Ignore any errors when removing directories, as tests might
+      // have already removed the directory.
+    }
+  });
+  return new_dir_handle;
+}
+
+async function createEmptyFile(test, name, parent) {
+  const handle = await parent.getFileHandle(name, {create: true});
+  test.add_cleanup(async () => {
+    try {
+      await parent.removeEntry(name);
+    } catch (e) {
+      // Ignore any errors when removing files, as tests might already remove
+      // the file.
+    }
+  });
+  // Make sure the file is empty.
+  assert_equals(await getFileSize(handle), 0);
+  return handle;
+}
+
+async function createFileWithContents(test, name, contents, parent) {
+  const handle = await createEmptyFile(test, name, parent);
+  const writer = await handle.createWritable();
+  await writer.write(new Blob([contents]));
+  await writer.close();
+  return handle;
+}
+
+function garbageCollect() {
+  // TODO(https://github.com/web-platform-tests/wpt/issues/7899): Change to
+  // some sort of cross-browser GC trigger.
+  if (self.gc)
+    self.gc();
+};
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessresourcesw3cimportlog"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/w3c-import.log (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/w3c-import.log                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/w3c-import.log       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,29 @@
</span><ins>+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+       https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/local-fs-test-helpers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-dedicated-worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-service-worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target-shared-worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.html
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/message-target.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-blob-helpers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-helpers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/messaging-serialize-helpers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/opaque-origin-sandbox.html
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sandboxed-fs-test-helpers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/sync-access-handle-test.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/resources/test-helpers.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any-expected.txt        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+
+FAIL Store handle in IndexedDB and read from pending transaction. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB and read from new transaction. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handles and blobs in IndexedDB. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB and read using a cursor. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB using inline keys. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.html        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=/IndexedDB/support-promises.js
+// META: script=script-tests/FileSystemBaseHandle-IndexedDB.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker-expected.txt 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+
+FAIL Store handle in IndexedDB and read from pending transaction. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB and read from new transaction. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handles and blobs in IndexedDB. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB and read using a cursor. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Store handle in IndexedDB using inline keys. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleIndexedDBhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.worker.html 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any-expected.txt      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+
+FAIL isSameEntry for identical directory handles returns true promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different directories returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different handles for the same directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for identical file handles returns true promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different files returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different handles for the same file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry comparing a file to a file in a different directory returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry comparing a file to a directory returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.html      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-isSameEntry.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+
+FAIL isSameEntry for identical directory handles returns true promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different directories returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different handles for the same directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for identical file handles returns true promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different files returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry for different handles for the same file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry comparing a file to a file in a different directory returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL isSameEntry comparing a file to a directory returns false promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleisSameEntryhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.worker.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+
+FAIL Send and receive messages using a broadcast channel in an iframe, dedicated worker and service worker. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageBroadcastChannelhttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+// META: script=/service-workers/service-worker/resources/test-helpers.sub.js
+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window-expected.txt     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+
+FAIL Fail to send and receive messages using a cross origin iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send and receive messages using a cross origin message port in an iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send to a sandboxed iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send messages using a message port to a sandboxed iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send messages to a data URI iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send messages using a message port in a data URI iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send and receive messages using a cross origin window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send and receive messages using a cross origin message port in a window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send messages to  a sandboxed window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Fail to send messages using a message port to a sandboxed window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.html     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageErrorhttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,9 @@
</span><ins>+// META: script=/common/get-host-info.sub.js
+// META: script=/service-workers/service-worker/resources/test-helpers.sub.js
+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-Error.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window-expected.txt        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+FAIL Send and receive messages using a message port in a same origin iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in a sandboxed same origin iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in a blob iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in an iframe srcdoc. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.html        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortframeshttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,5 @@
</span><ins>+
+FAIL Send and receive messages using a message port in a same origin window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in a blob window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in a sandboxed same origin window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortwindowshttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL Send and receive messages using a message port in a dedicated worker. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a message port in a service worker. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageMessagePortworkershttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+// META: script=/service-workers/service-worker/resources/test-helpers.sub.js
+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+FAIL Send and receive messages using a same origin iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a sandboxed same origin iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a blob iframe. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using an iframe srcdoc. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageframeshttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-frames.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,5 @@
</span><ins>+
+FAIL Send and receive messages using a same origin window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a blob window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a sandboxed same origin window. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessagewindowshttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,7 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-windows.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL Send and receive messages using a dedicated worker. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Send and receive messages using a service worker. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandlepostMessageworkershttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+// META: script=/service-workers/service-worker/resources/test-helpers.sub.js
+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=resources/messaging-blob-helpers.js
+// META: script=resources/messaging-serialize-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-postMessage-workers.js
+// META: timeout=long
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,9 @@
</span><ins>+
+FAIL remove() to remove a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on an already removed file should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() to remove an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on an already removed directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a non-empty directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a directory recursively should delete all sub-items promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a file should ignore the recursive option promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemBaseHandle-remove.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,9 @@
</span><ins>+
+FAIL remove() to remove a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on an already removed file should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() to remove an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on an already removed directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a non-empty directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a directory recursively should delete all sub-items promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL remove() on a file should ignore the recursive option promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemBaseHandleremovehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.worker.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+
+FAIL getDirectoryHandle(create=false) rejects for non-existing directories promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) creates an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=false) returns existing directories promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) returns existing directories without erasing promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() when a file already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with empty name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with "." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with ".." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=false) with a path separator when the directory exists promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) with a path separator promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+
+FAIL getDirectoryHandle(create=false) rejects for non-existing directories promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) creates an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=false) returns existing directories promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) returns existing directories without erasing promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() when a file already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with empty name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with "." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle() with ".." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=false) with a path separator when the directory exists promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getDirectoryHandle(create=true) with a path separator promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetDirectoryHandlehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,13 @@
</span><ins>+
+FAIL getFileHandle(create=false) rejects for non-existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) creates an empty file for non-existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) returns existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) returns existing files without erasing promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) when a directory already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) when a directory already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with empty name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with "." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with ".." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) with a path separator when the file exists. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) with a path separator promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemDirectoryHandle-getFileHandle.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,13 @@
</span><ins>+
+FAIL getFileHandle(create=false) rejects for non-existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) creates an empty file for non-existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) returns existing files promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) returns existing files without erasing promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) when a directory already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) when a directory already exists with the same name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with empty name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with "." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle() with ".." name promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=false) with a path separator when the file exists. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFileHandle(create=true) with a path separator promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandlegetFileHandlehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker.html        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+
+FAIL returning early from an iteration doesn't crash promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL @@asyncIterator: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL entries: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL values: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL keys: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL iteration while iterator gets garbage collected promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemDirectoryHandle-iteration.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+
+FAIL returning early from an iteration doesn't crash promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL @@asyncIterator: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL entries: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL values: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL keys: full iteration works promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL iteration while iterator gets garbage collected promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleiterationhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.worker.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,11 @@
</span><ins>+
+FAIL removeEntry() to remove a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on an already removed file should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() to remove an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on a non-empty directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on a directory recursively should delete all sub-items promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with empty name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with "." name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with ".." name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with a path separator should fail. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.html 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemDirectoryHandle-removeEntry.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,11 @@
</span><ins>+
+FAIL removeEntry() to remove a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on an already removed file should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() to remove an empty directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on a non-empty directory should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() on a directory recursively should delete all sub-items promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with empty name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with "." name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with ".." name should fail promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL removeEntry() with a path separator should fail. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleremoveEntryhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any-expected.txt     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+FAIL Resolve returns empty array for same directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns correct path promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns correct path with non-ascii characters promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns null when entry is not a child promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.html     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemDirectoryHandle-resolve.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker-expected.txt      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+FAIL Resolve returns empty array for same directory promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns correct path promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns correct path with non-ascii characters promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Resolve returns null when entry is not a child promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemDirectoryHandleresolvehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.worker.html      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+
+FAIL Attempt to create a sync access handle. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlecreatesyncaccesshandlededicatedworkerhttpstentativewindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=resources/messaging-helpers.js
+// META: script=script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js
+
+// This variable allows the test to differentiate between local and sandboxed
+// file systems, since createSyncAccessHandle() behavior is different each one.
+const file_system_type = 'sandboxed';
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL getFile() provides a file that can be sliced promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFile() returns last modified time promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemFileHandle-getFile.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL getFile() provides a file that can be sliced promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getFile() returns last modified time promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlegetFilehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.worker.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker-expected.txt     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL There can only be one open access handle at any given time promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL An access handle from one file does not interfere with the creation of an access handle on another file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.html     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemFileHandlesyncaccesshandlelockhttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,36 @@
</span><ins>+importScripts('/resources/testharness.js');
+
+'use strict';
+
+promise_test(async t => {
+  const dir = await navigator.storage.getDirectory();
+  const fileHandle = await dir.getFileHandle('OPFS.test', {create: true});
+
+  const syncHandle1 = await fileHandle.createSyncAccessHandle();
+  await promise_rejects_dom(
+      t, 'InvalidStateError', fileHandle.createSyncAccessHandle());
+
+  await syncHandle1.close();
+  const syncHandle2 = await fileHandle.createSyncAccessHandle();
+  await syncHandle2.close();
+}, 'There can only be one open access handle at any given time');
+
+promise_test(async t => {
+  const dir = await navigator.storage.getDirectory();
+  const fooFileHandle = await dir.getFileHandle('foo.test', {create: true});
+  const barFileHandle = await dir.getFileHandle('bar.test', {create: true});
+
+  const fooSyncHandle = await fooFileHandle.createSyncAccessHandle();
+  t.add_cleanup(() => fooSyncHandle.close());
+
+  const barSyncHandle1 = await barFileHandle.createSyncAccessHandle();
+  await promise_rejects_dom(
+      t, 'InvalidStateError', barFileHandle.createSyncAccessHandle());
+
+  await barSyncHandle1.close();
+  const barSyncHandle2 = await barFileHandle.createSyncAccessHandle();
+  await barSyncHandle2.close();
+}, 'An access handle from one file does not interfere with the creation of an' +
+     ' access handle on another file');
+
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker-expected.txt 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,14 @@
</span><ins>+
+FAIL SyncAccessHandle.close is idempotent promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.close is idempotent when called immediately promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.read fails after SyncAccessHandle.close settles promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.read fails immediately after calling SyncAccessHandle.close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.write fails after SyncAccessHandle.close settles promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.write fails immediately after calling SyncAccessHandle.close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.flush fails after SyncAccessHandle.close settles promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.flush fails immediately after calling SyncAccessHandle.close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.getSize fails after SyncAccessHandle.close settles promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.getSize fails immediately after calling SyncAccessHandle.close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.truncate fails after SyncAccessHandle.close settles promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.truncate fails immediately after calling SyncAccessHandle.close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.html 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleclosehttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,90 @@
</span><ins>+importScripts("/resources/testharness.js");
+importScripts('resources/sync-access-handle-test.js');
+
+'use strict';
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  assert_equals(await handle.close(), undefined);
+}, 'SyncAccessHandle.close is idempotent');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  assert_equals(await handle.close(), undefined);
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.close is idempotent when called immediately');
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  const readBuffer = new Uint8Array(4);
+  assert_throws_dom('InvalidStateError', () => handle.read(readBuffer, {at: 0}));
+}, 'SyncAccessHandle.read fails after SyncAccessHandle.close settles');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  const readBuffer = new Uint8Array(4);
+  assert_throws_dom('InvalidStateError', () => handle.read(readBuffer, {at: 0}));
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.read fails immediately after calling SyncAccessHandle.close');
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  const writeBuffer = new Uint8Array(4);
+  writeBuffer.set([96, 97, 98, 99]);
+  assert_throws_dom('InvalidStateError', () => handle.write(writeBuffer, {at: 0}));
+}, 'SyncAccessHandle.write fails after SyncAccessHandle.close settles');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  const writeBuffer = new Uint8Array(4);
+  writeBuffer.set([96, 97, 98, 99]);
+  assert_throws_dom('InvalidStateError', () => handle.write(writeBuffer, {at: 0}));
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.write fails immediately after calling SyncAccessHandle.close');
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.flush());
+}, 'SyncAccessHandle.flush fails after SyncAccessHandle.close settles');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.flush());
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.flush fails immediately after calling SyncAccessHandle.close');
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.getSize());
+}, 'SyncAccessHandle.getSize fails after SyncAccessHandle.close settles');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.getSize());
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.getSize fails immediately after calling SyncAccessHandle.close');
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.close(), undefined);
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.truncate(4));
+}, 'SyncAccessHandle.truncate fails after SyncAccessHandle.close settles');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const closePromise = handle.close();
+
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.truncate(4));
+  assert_equals(await closePromise, undefined);
+}, 'SyncAccessHandle.truncate fails immediately after calling SyncAccessHandle.close');
+
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker-expected.txt 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,6 @@
</span><ins>+
+FAIL Test flush on an empty file. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.read returns bytes written by SyncAccessHandle.write after SyncAccessHandle.flush promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.read fails when there is a pending SyncAccessHandle.flush promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL SyncAccessHandle.write fails when there is a pending SyncAccessHandle.flush promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.html 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandleflushhttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,49 @@
</span><ins>+importScripts('/resources/testharness.js');
+importScripts('resources/sync-access-handle-test.js');
+
+'use strict';
+
+sync_access_handle_test(async (t, handle) => {
+  await handle.flush();
+}, 'Test flush on an empty file.');
+
+sync_access_handle_test(async (t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  const text = 'Hello Storage Foundation';
+  const writeBuffer = new TextEncoder().encode(text);
+  handle.write(writeBuffer, {at: 0});
+  await handle.flush();
+  let readBuffer = new Uint8Array(text.length);
+  handle.read(readBuffer, {at: 0});
+  assert_equals(
+      text, new TextDecoder().decode(readBuffer),
+      'Check that the written bytes and the read bytes match');
+},
+'SyncAccessHandle.read returns bytes written by SyncAccessHandle.write' +
+    ' after SyncAccessHandle.flush');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const flushPromise = handle.flush();
+  const readBuffer = new Uint8Array(4);
+  assert_throws_dom(
+      'InvalidStateError', () => handle.read(readBuffer, {at: 0}));
+  assert_equals(await flushPromise, undefined);
+},
+'SyncAccessHandle.read fails when there is a pending SyncAccessHandle.flush');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const flushPromise = handle.flush();
+  const writeBuffer = new Uint8Array(4);
+  writeBuffer.set([96, 97, 98, 99]);
+  assert_throws_dom(
+      'InvalidStateError', () => handle.write(writeBuffer, {at: 0}));
+  assert_equals(await flushPromise, undefined);
+},
+'SyncAccessHandle.write fails when there is a pending SyncAccessHandle.flush');
+
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker-expected.txt       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+
+FAIL test SyncAccessHandle.getSize after SyncAccessHandle.write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL test createSyncAccessHandle.getSize with pending operation promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.html       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlegetSizehttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,26 @@
</span><ins>+importScripts("/resources/testharness.js");
+importScripts('resources/sync-access-handle-test.js');
+
+'use strict';
+
+sync_access_handle_test(async (testCase, handle) => {
+  assert_equals(await handle.getSize(), 0);
+  const bufferSize = 4;
+  const writeBuffer = new Uint8Array(bufferSize);
+  writeBuffer.set([96, 97, 98, 99]);
+  handle.write(writeBuffer, {at: 0});
+  assert_equals(await handle.getSize(), bufferSize);
+  let offset = 3;
+  handle.write(writeBuffer, {at: offset});
+  assert_equals(await handle.getSize(), bufferSize + offset);
+  offset = 10;
+  handle.write(writeBuffer, {at: offset});
+  assert_equals(await handle.getSize(), bufferSize + offset);
+}, 'test SyncAccessHandle.getSize after SyncAccessHandle.write');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const getSizePromise = handle.getSize();
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.getSize());
+  assert_equals(await getSizePromise, 0);
+}, 'test createSyncAccessHandle.getSize with pending operation');
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+
+FAIL Test reading an empty file through a sync access handle. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test writing and reading through a sync access handle. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test second write that is bigger than the first write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test second write that is smaller than the first write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test initial write with an offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test overwriting the file at an offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test read at an offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL Test reading at a negative offset fails. promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandlereadwritehttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,189 @@
</span><ins>+importScripts("/resources/testharness.js");
+importScripts('resources/sync-access-handle-test.js');
+
+'use strict';
+
+sync_access_handle_test((t, handle) => {
+  const readBuffer = new Uint8Array(24);
+  const readBytes = handle.read(readBuffer, {at: 0});
+  assert_equals(0, readBytes, 'Check that no bytes were read');
+}, 'Test reading an empty file through a sync access handle.');
+
+sync_access_handle_test((t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  const text = 'Hello Storage Foundation';
+  const writeBuffer = new TextEncoder().encode(text);
+  const writtenBytes = handle.write(writeBuffer, {at: 0});
+  assert_equals(
+      writeBuffer.byteLength, writtenBytes,
+      'Check that all bytes were written.');
+  let readBuffer = new Uint8Array(writtenBytes);
+  let readBytes = handle.read(readBuffer, {at: 0});
+  assert_equals(writtenBytes, readBytes, 'Check that all bytes were read');
+  assert_equals(
+      text, new TextDecoder().decode(readBuffer),
+      'Check that the written bytes and the read bytes match');
+
+  // Test a read of less bytes than available.
+  const expected = 'Storage';
+  readBuffer = new Uint8Array(expected.length);
+  readBytes = handle.read(readBuffer, {at: text.indexOf(expected)});
+  assert_equals(readBuffer.length, readBytes, 'Check that all bytes were read');
+  const actual = new TextDecoder().decode(readBuffer);
+  assert_equals(
+      expected, actual,
+      'Partial read returned unexpected contents');
+}, 'Test writing and reading through a sync access handle.');
+
+sync_access_handle_test((t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  for (text of ['Hello', 'Longer Text']) {
+    const writeBuffer = new TextEncoder().encode(text);
+    const writtenBytes = handle.write(writeBuffer, {at: 0});
+    assert_equals(
+        writeBuffer.byteLength, writtenBytes,
+        'Check that all bytes were written.');
+    const readBuffer = new Uint8Array(writtenBytes);
+    const readBytes = handle.read(readBuffer, {at: 0});
+    assert_equals(writtenBytes, readBytes, 'Check that all bytes were read');
+    assert_equals(
+        text, new TextDecoder().decode(readBuffer),
+        'Check that the written bytes and the read bytes match');
+  }
+}, 'Test second write that is bigger than the first write');
+
+sync_access_handle_test((t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  for (tuple
+           of [{input: 'Hello World', expected: 'Hello World'},
+               {input: 'foobar', expected: 'foobarWorld'}]) {
+    const text = tuple.input;
+    const expected = tuple.expected;
+    const writeBuffer = new TextEncoder().encode(text);
+    const writtenBytes = handle.write(writeBuffer, {at: 0});
+    assert_equals(
+        writeBuffer.byteLength, writtenBytes,
+        'Check that all bytes were written.');
+    const readBuffer = new Uint8Array(expected.length);
+    const readBytes = handle.read(readBuffer, {at: 0});
+    assert_equals(expected.length, readBytes, 'Check that all bytes were read');
+    assert_equals(
+        expected, new TextDecoder().decode(readBuffer),
+        'Check that the written bytes and the read bytes match');
+  }
+}, 'Test second write that is smaller than the first write');
+
+sync_access_handle_test((t, handle) => {
+  const expected = 17;
+  const writeBuffer = new Uint8Array(1);
+  writeBuffer[0] = expected;
+  const offset = 5;
+  const writtenBytes = handle.write(writeBuffer, {at: offset});
+  assert_equals(
+      writeBuffer.byteLength, writtenBytes,
+      'Check that all bytes were written.');
+  const fileLength = writeBuffer.byteLength + offset;
+  const readBuffer = new Uint8Array(fileLength);
+  const readBytes = handle.read(readBuffer, {at: 0});
+  assert_equals(fileLength, readBytes, 'Check that all bytes were read');
+  for (let i = 0; i < offset; ++i) {
+    assert_equals(
+        readBuffer[i], 0,
+        `Gaps in the file should be filled with 0, but got ${readBuffer[i]}.`);
+  }
+
+  assert_equals(
+      readBuffer[offset], expected,
+      'Gaps in the file should be filled with 0.');
+}, 'Test initial write with an offset');
+
+sync_access_handle_test((t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  for (tuple
+           of [{input: 'Hello World', expected: 'Hello World', offset: 0},
+               {input: 'foobar', expected: 'Hello foobar', offset: 6}]) {
+    const text = tuple.input;
+    const expected = tuple.expected;
+    const offset = tuple.offset;
+    const writeBuffer = new TextEncoder().encode(text);
+    const writtenBytes = handle.write(writeBuffer, {at: offset});
+    assert_equals(
+        writeBuffer.byteLength, writtenBytes,
+        'Check that all bytes were written.');
+    const readBuffer = new Uint8Array(expected.length);
+    const readBytes = handle.read(readBuffer, {at: 0});
+    assert_equals(expected.length, readBytes, 'Check that all bytes were read');
+    const actual = new TextDecoder().decode(readBuffer);
+    assert_equals(
+        expected, actual,
+        'Check content read from the handle');
+  }
+}, 'Test overwriting the file at an offset');
+
+sync_access_handle_test((t, handle) => {
+  if (!('TextEncoder' in self)) {
+    return;
+  }
+  const encoder = new TextEncoder();
+  const decoder = new TextDecoder();
+
+  const text = 'Hello Storage Foundation';
+  const writeBuffer = new TextEncoder().encode(text);
+  const writtenBytes = handle.write(writeBuffer, {at: 0});
+  assert_equals(
+      writeBuffer.byteLength, writtenBytes,
+      'Check that all bytes were written.');
+  const bufferLength = text.length;
+  for (tuple
+           of [{offset: 0, expected: text},
+               {offset: 6, expected: text.substring(6)}]) {
+    const offset = tuple.offset;
+    const expected = tuple.expected;
+
+    const readBuffer = new Uint8Array(bufferLength);
+    const readBytes = handle.read(readBuffer, {at: offset});
+    assert_equals(expected.length, readBytes, 'Check that all bytes were read');
+    const actual = new TextDecoder().decode(readBuffer);
+    assert_true(
+        actual.startsWith(expected),
+        `Expected to read ${expected} but the actual value was ${actual}.`);
+  }
+
+  const readBuffer = new Uint8Array(bufferLength);
+  // Offset is greater than the file length.
+  const readBytes = handle.read(readBuffer, {at: bufferLength + 1});
+  assert_equals(0, readBytes, 'Check that no bytes were read');
+  for (let i = 0; i < readBuffer.byteLength; ++i) {
+    assert_equals(0, readBuffer[i], 'Check that the read buffer is unchanged.');
+  }
+}, 'Test read at an offset');
+
+sync_access_handle_test((t, handle) => {
+  const readBuffer = new Uint8Array(24);
+  assert_throws_dom(
+    'NotSupportedError', () => handle.read(readBuffer, { at: -1 }));
+}, 'Test reading at a negative offset fails.');
+
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker-expected.txt      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,5 @@
</span><ins>+
+FAIL test createSyncAccessHandle.truncate with pending operation promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL test SyncAccessHandle.truncate with different sizes promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL test SyncAccessHandle.truncate after SyncAccessHandle.write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.html      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemSyncAccessHandletruncatehttpstentativeworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,42 @@
</span><ins>+importScripts("/resources/testharness.js");
+importScripts('resources/sync-access-handle-test.js');
+
+'use strict';
+
+sync_access_handle_test(async (testCase, handle) => {
+  const getSizePromise = handle.getSize();
+  await promise_rejects_dom(testCase, 'InvalidStateError', handle.truncate(4));
+  assert_equals(await getSizePromise, 0);
+}, 'test createSyncAccessHandle.truncate with pending operation');
+
+sync_access_handle_test(async (testCase, handle) => {
+  await handle.truncate(4);
+  assert_equals(await handle.getSize(), 4);
+
+  await handle.truncate(2);
+  assert_equals(await handle.getSize(), 2);
+
+  await handle.truncate(7);
+  assert_equals(await handle.getSize(), 7);
+
+  await promise_rejects_js(testCase, TypeError, handle.truncate(-4));
+}, 'test SyncAccessHandle.truncate with different sizes');
+
+sync_access_handle_test(async (testCase, handle) => {
+  const writeBuffer = new Uint8Array(4);
+  writeBuffer.set([96, 97, 98, 99]);
+  handle.write(writeBuffer, {at: 0});
+
+  await handle.truncate(2);
+  let readBuffer = new Uint8Array(6);
+  assert_equals(2, handle.read(readBuffer, {at: 0}));
+  let expected = new Uint8Array(6);
+  expected.set([96, 97, 0, 0, 0, 0]);
+  assert_array_equals(expected, readBuffer);
+
+  // Resize the file to 6, expect that everything beyond the old size is '0'.
+  await handle.truncate(6);
+  assert_equals(6, handle.read(readBuffer, {at: 0}));
+  assert_array_equals(expected, readBuffer);
+}, 'test SyncAccessHandle.truncate after SyncAccessHandle.write');
+done();
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+
+FAIL can be piped to with a string promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with an ArrayBuffer promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a Blob promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a param object with write command promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a param object with multiple commands promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL multiple operations can be queued promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL plays well with fetch promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL abort() aborts write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,4 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=../streams/resources/recording-streams.js
+// META: script=script-tests/FileSystemWritableFileStream-piped.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker-expected.txt     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,10 @@
</span><ins>+
+FAIL can be piped to with a string promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with an ArrayBuffer promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a Blob promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a param object with write command promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL can be piped to with a param object with multiple commands promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL multiple operations can be queued promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL plays well with fetch promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL abort() aborts write promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreampipedhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.worker.html     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+
+FAIL write() with an empty blob to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a blob to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with WriteParams without position to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a string to an empty file with zero offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a blob to an empty file with zero offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called consecutively appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() WriteParams without position and string appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() WriteParams without position and blob appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with a string and a valid offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with a blob and a valid offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with an offset beyond the end of the file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an empty string to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a valid utf-8 string promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a string with unix line ending preserved promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a string with windows line ending preserved promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an empty array buffer to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a valid typed array buffer promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: close() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: writable file streams make atomic changes on close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: write() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: truncate() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: close() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: only one close() operation may succeed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: writable file stream persists file on close, even if file is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getWriter() can be used promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: truncate missing size param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: write missing data param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: seek missing position param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an invalid blob to an empty file should reject promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemWritableFileStream-write.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker-expected.txt     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+
+FAIL write() with an empty blob to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a blob to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with WriteParams without position to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a string to an empty file with zero offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() a blob to an empty file with zero offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called consecutively appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() WriteParams without position and string appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() WriteParams without position and blob appends promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with a string and a valid offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with a blob and a valid offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() called with an offset beyond the end of the file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an empty string to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a valid utf-8 string promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a string with unix line ending preserved promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a string with windows line ending preserved promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an empty array buffer to an empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with a valid typed array buffer promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: close() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: writable file streams make atomic changes on close promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: write() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: truncate() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: close() after close() fails promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: only one close() operation may succeed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL atomic writes: writable file stream persists file on close, even if file is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL getWriter() can be used promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: truncate missing size param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: write missing data param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL WriteParams: seek missing position param promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() with an invalid blob to an empty file should reject promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamwritehttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.worker.html     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any-expected.txt  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+
+FAIL truncate() to shrink a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL truncate() to grow a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL truncate() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable({keepExistingData: true}): atomic writable file stream initialized with source contents promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable({keepExistingData: false}): atomic writable file stream initialized with empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL cursor position: truncate size > offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL cursor position: truncate size < offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL commands are queued, stream is unlocked after each operation promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.html  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+// META: script=resources/test-helpers.js
+// META: script=resources/sandboxed-fs-test-helpers.js
+// META: script=script-tests/FileSystemWritableFileStream.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyworkerexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker-expected.txt   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+
+FAIL truncate() to shrink a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL truncate() to grow a file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL write() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL truncate() fails when parent directory is removed promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable({keepExistingData: true}): atomic writable file stream initialized with source contents promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL createWritable({keepExistingData: false}): atomic writable file stream initialized with empty file promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL cursor position: truncate size > offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL cursor position: truncate size < offset promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+FAIL commands are queued, stream is unlocked after each operation promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'navigator.storage.getDirectory')"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccesssandboxed_FileSystemWritableFileStreamhttpsanyworkerhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.worker.html   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleIndexedDBjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,126 @@
</span><ins>+'use strict';
+
+directory_test(async (t, root_dir) => {
+    const handles = await create_file_system_handles(t, root_dir);
+
+    const db = await createDatabase(t, db => {
+      const store = db.createObjectStore('store');
+    });
+    t.add_cleanup(() => deleteAllDatabases(t));
+
+    const value = handles;
+
+    const tx = db.transaction('store', 'readwrite');
+    const store = tx.objectStore('store');
+    await promiseForRequest(t, store.put(value, 'key'));
+    const result = await promiseForRequest(t, store.get('key'));
+
+    await promiseForTransaction(t, tx);
+
+    assert_true(Array.isArray(result), 'Result should be an array');
+    assert_equals(result.length, value.length);
+    await assert_equals_cloned_handles(result, value);
+}, 'Store handle in IndexedDB and read from pending transaction.');
+
+directory_test(async (t, root_dir) => {
+    const handles = await create_file_system_handles(t, root_dir);
+
+    const db = await createDatabase(t, db => {
+      const store = db.createObjectStore('store');
+    });
+    t.add_cleanup(() => deleteAllDatabases(t));
+
+    const value = handles;
+
+    let tx = db.transaction('store', 'readwrite');
+    let store = tx.objectStore('store');
+    await promiseForRequest(t, store.put(value, 'key'));
+    await promiseForTransaction(t, tx);
+
+    tx = db.transaction('store', 'readonly');
+    store = tx.objectStore('store');
+    const result = await promiseForRequest(t, store.get('key'));
+    await promiseForTransaction(t, tx);
+
+    assert_true(Array.isArray(result), 'Result should be an array');
+    assert_equals(result.length, value.length);
+    await assert_equals_cloned_handles(result, value);
+}, 'Store handle in IndexedDB and read from new transaction.');
+
+directory_test(async (t, root_dir) => {
+    const handles = await create_file_system_handles(t, root_dir);
+
+    const db = await createDatabase(t, db => {
+      const store = db.createObjectStore('store');
+    });
+    t.add_cleanup(() => deleteAllDatabases(t));
+
+    const value = {handles, blob: new Blob(["foobar"])};
+
+    let tx = db.transaction('store', 'readwrite');
+    let store = tx.objectStore('store');
+    await promiseForRequest(t, store.put(value, 'key'));
+    await promiseForTransaction(t, tx);
+
+    tx = db.transaction('store', 'readonly');
+    store = tx.objectStore('store');
+    const result = await promiseForRequest(t, store.get('key'));
+    await promiseForTransaction(t, tx);
+
+    assert_true(Array.isArray(result.handles), 'Result should be an array');
+    assert_equals(result.handles.length, value.handles.length);
+    await assert_equals_cloned_handles(result.handles, value.handles);
+
+    assert_equals(await result.blob.text(), await value.blob.text());
+}, 'Store handles and blobs in IndexedDB.');
+
+directory_test(async (t, root_dir) => {
+    const handles = await create_file_system_handles(t, root_dir);
+
+    const db = await createDatabase(t, db => {
+      const store = db.createObjectStore('store');
+    });
+    t.add_cleanup(() => deleteAllDatabases(t));
+
+    const value = handles;
+
+    let tx = db.transaction('store', 'readwrite');
+    let store = tx.objectStore('store');
+    await promiseForRequest(t, store.put(value, 'key'));
+    await promiseForTransaction(t, tx);
+
+    tx = db.transaction('store', 'readonly');
+    store = tx.objectStore('store');
+    let cursor_request = store.openCursor();
+    await requestWatcher(t, cursor_request).wait_for('success');
+    const result = cursor_request.result.value;
+    await promiseForTransaction(t, tx);
+
+    assert_true(Array.isArray(result), 'Result should be an array');
+    assert_equals(result.length, value.length);
+    await assert_equals_cloned_handles(result, value);
+}, 'Store handle in IndexedDB and read using a cursor.');
+
+directory_test(async (t, root_dir) => {
+    const handles = await create_file_system_handles(t, root_dir);
+
+    const db = await createDatabase(t, db => {
+      const store = db.createObjectStore('store', {keyPath: 'key'});
+    });
+    t.add_cleanup(() => deleteAllDatabases(t));
+
+    const value = handles;
+    let tx = db.transaction('store', 'readwrite');
+    let store = tx.objectStore('store');
+    await promiseForRequest(t, store.put({key: 'key', value}));
+    await promiseForTransaction(t, tx);
+
+    tx = db.transaction('store', 'readonly');
+    store = tx.objectStore('store');
+    const result = await promiseForRequest(t, store.get('key'));
+    await promiseForTransaction(t, tx);
+
+    assert_true(Array.isArray(result.value), 'Result should be an array');
+    assert_equals(result.value.length, value.length);
+    await assert_equals_cloned_handles(result.value, value);
+}, 'Store handle in IndexedDB using inline keys.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleisSameEntryjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,62 @@
</span><ins>+'use strict';
+
+directory_test(async (t, root_dir) => {
+  assert_true(await root_dir.isSameEntry(root_dir));
+
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+  assert_true(await subdir.isSameEntry(subdir));
+}, 'isSameEntry for identical directory handles returns true');
+
+directory_test(async (t, root_dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+
+  assert_false(await root_dir.isSameEntry(subdir));
+  assert_false(await subdir.isSameEntry(root_dir));
+}, 'isSameEntry for different directories returns false');
+
+directory_test(async (t, root_dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+  const subdir2 = await root_dir.getDirectoryHandle('subdir-name');
+
+  assert_true(await subdir.isSameEntry(subdir2));
+  assert_true(await subdir2.isSameEntry(subdir));
+}, 'isSameEntry for different handles for the same directory');
+
+directory_test(async (t, root_dir) => {
+  const handle = await createEmptyFile(t, 'mtime.txt', root_dir);
+
+  assert_true(await handle.isSameEntry(handle));
+}, 'isSameEntry for identical file handles returns true');
+
+directory_test(async (t, root_dir) => {
+  const handle1 = await createEmptyFile(t, 'mtime.txt', root_dir);
+  const handle2 = await createEmptyFile(t, 'foo.txt', root_dir);
+
+  assert_false(await handle1.isSameEntry(handle2));
+  assert_false(await handle2.isSameEntry(handle1));
+}, 'isSameEntry for different files returns false');
+
+directory_test(async (t, root_dir) => {
+  const handle1 = await createEmptyFile(t, 'mtime.txt', root_dir);
+  const handle2 = await root_dir.getFileHandle('mtime.txt');
+
+  assert_true(await handle1.isSameEntry(handle2));
+  assert_true(await handle2.isSameEntry(handle1));
+}, 'isSameEntry for different handles for the same file');
+
+directory_test(async (t, root_dir) => {
+  const handle1 = await createEmptyFile(t, 'mtime.txt', root_dir);
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+  const handle2 = await createEmptyFile(t, 'mtime.txt', subdir);
+
+  assert_false(await handle1.isSameEntry(handle2));
+  assert_false(await handle2.isSameEntry(handle1));
+}, 'isSameEntry comparing a file to a file in a different directory returns false');
+
+directory_test(async (t, root_dir) => {
+  const handle1 = await createEmptyFile(t, 'mtime.txt', root_dir);
+  const handle2 = await createDirectory(t, 'subdir-name', root_dir);
+
+  assert_false(await handle1.isSameEntry(handle2));
+  assert_false(await handle2.isSameEntry(handle1));
+}, 'isSameEntry comparing a file to a directory returns false');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageBroadcastChanneljs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,82 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+//    /service-workers/service-worker/resources/test-helpers.sub.js
+
+// Sets up a new broadcast channel in |target|. Posts a message instructing
+// |target| to open the broadcast channel using |broadcast_channel_name|.
+async function create_broadcast_channel(
+  test, broadcast_channel_name, receiver, target, target_origin) {
+  target.postMessage(
+    { type: 'create-broadcast-channel', broadcast_channel_name },
+    { targetOrigin: target_origin });
+  const event_watcher = new EventWatcher(test, receiver, 'message');
+
+  // Wait until |target| is listening to the broad cast channel.
+  const message_event = await event_watcher.wait_for('message');
+  assert_equals(message_event.data.type, 'broadcast-channel-created',
+    'The message target must receive a "broadcast-channel-created" message ' +
+    'response.');
+}
+
+// This test is very similar to 'FileSystemBaseHandle-postMessage.js'. It
+// starts by creating three message targets for the broadcast channel:
+// an iframe, dedicated worker and a service worker. After setup, an array
+// of FileSystemHandles is sent across the broadcast channel. The test
+// expects three responses -- one from each message target.
+directory_test(async (t, root) => {
+  const broadcast_channel_name = 'file-system-file-handle-channel';
+  const broadcast_channel = new BroadcastChannel(broadcast_channel_name);
+  const broadcast_channel_event_watcher =
+    new EventWatcher(t, broadcast_channel, 'message');
+
+  const iframe = await add_iframe(t, { src: kDocumentMessageTarget });
+  await create_broadcast_channel(
+    t, broadcast_channel_name, self, iframe.contentWindow, '*');
+
+  const scope = `${kServiceWorkerMessageTarget}` +
+    '?post-message-to-broadcast-channel-with-file-handle';
+
+  const registration = await create_service_worker(
+    t, kServiceWorkerMessageTarget, scope);
+
+  await create_broadcast_channel(
+    t, broadcast_channel_name,
+    navigator.serviceWorker, registration.installing);
+
+  const dedicated_worker =
+    create_dedicated_worker(t, kDedicatedWorkerMessageTarget);
+
+  await create_broadcast_channel(
+    t, broadcast_channel_name, dedicated_worker, dedicated_worker);
+
+  const handles = await create_file_system_handles(t, root);
+
+  broadcast_channel.postMessage(
+    { type: 'receive-file-system-handles', cloned_handles: handles });
+
+  const expected_response_count = 3;
+  const responses = [];
+  for (let i = 0; i < expected_response_count; ++i) {
+    const message_event =
+      await broadcast_channel_event_watcher.wait_for('message');
+    responses.push(message_event.data);
+  }
+
+  const expected_serialized_handles = await serialize_handles(handles);
+
+  for (let i = 0; i < responses.length; ++i) {
+    assert_equals(responses[i].type, 'receive-serialized-file-system-handles',
+      'The test runner must receive a "serialized-file-system-handles" ' +
+      `message response. Actual response: ${responses[i]}`);
+
+    assert_equals_serialized_handles(
+      responses[i].serialized_handles, expected_serialized_handles);
+
+    await assert_equals_cloned_handles(responses[i].cloned_handles, handles);
+  }
+}, 'Send and receive messages using a broadcast channel in an iframe, ' +
+'dedicated worker and service worker.');
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageErrorjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,244 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+//    /common/get-host-info.sub.js
+//    /service-workers/service-worker/resources/test-helpers.sub.js
+
+// Define URL constants for cross origin windows.
+const kRemoteOrigin = get_host_info().HTTPS_REMOTE_ORIGIN;
+const kRemoteOriginDocumentMessageTarget = `${kRemoteOrigin}${base_path()}` +
+  kDocumentMessageTarget;
+
+// Sending a FileSystemHandle to a cross origin |target| through postMessage()
+// must dispatch the 'messageerror' event.
+//
+// This test sends a FileSystemHandle to |target|. |target| responds with a
+// serialized MessageEvent from the 'messageerror' event, allowing the test
+// runner to verify MessageEvent properties.
+async function do_send_message_error_test(
+  test,
+  root_dir,
+  receiver,
+  target,
+  target_origin,
+  // False when the MessageEvent's source is null.
+  expected_has_source,
+  // The origin of MessageEvents received by |target|.
+  expected_origin) {
+  const message_watcher = new EventWatcher(test, receiver, 'message');
+
+  // Send a file to |target|.
+  const file = await createFileWithContents(
+    test, 'test-error-file', 'test-error-file-contents', root_dir);
+  target.postMessage(
+    { type: 'receive-file-system-handles', cloned_file_system_handles: [file] },
+    { targetOrigin: target_origin });
+
+  // Wait for |target| to respond with results.
+  let message_event = await message_watcher.wait_for('message');
+  const first_response = message_event.data;
+  assert_equals(first_response.type, 'serialized-message-error',
+    'The test runner must receive a "serialized-message-error" message ' +
+    'in response to a FileSystemFileHandle message.');
+
+  // Verify the results.
+  assert_equals_serialized_message_error_event(
+    first_response.serialized_message_error_event,
+    expected_origin, expected_has_source);
+
+  // Send a directory to |target|.
+  const directory = await createDirectory(
+    test, 'test-error-directory', root_dir);
+
+  target.postMessage(
+    {
+      type: 'receive-file-system-handles',
+      cloned_file_system_handles: [directory]
+    }, { targetOrigin: target_origin });
+
+  // Wait for |target| to respond with results.
+  message_event = await message_watcher.wait_for('message');
+  const second_response = message_event.data;
+  assert_equals(second_response.type, 'serialized-message-error',
+    'The test runner must receive a "serialized-message-error" message ' +
+    'response to a FileSystemDirectoryHandle message.');
+
+  // Verify the results.
+  assert_equals_serialized_message_error_event(
+    second_response.serialized_message_error_event,
+    expected_origin, expected_has_source);
+}
+
+// This test receives a FileSystemHandle from |target|. This test runner
+// must dispatch the 'messageerror' event after receiving a handle from target.
+async function do_receive_message_error_test(
+  test,
+  receiver,
+  target,
+  target_origin,
+  // False when the MessageEvent's source is null.
+  expected_has_source,
+  // The origin of MessageEvents received by this test runner.
+  expected_origin) {
+  const error_watcher = new EventWatcher(test, receiver, 'messageerror');
+
+  // Receive a file from |target|.
+  target.postMessage(
+    { type: 'create-file' }, { targetOrigin: target_origin });
+  const first_error = await error_watcher.wait_for('messageerror');
+  const serialized_first_error = serialize_message_error_event(first_error);
+  assert_equals_serialized_message_error_event(
+    serialized_first_error, expected_origin, expected_has_source);
+
+  // Receive a directory from |target|.
+  target.postMessage(
+    { type: 'create-directory' }, { targetOrigin: target_origin });
+  const second_error = await error_watcher.wait_for('messageerror');
+  const serialized_second_error = serialize_message_error_event(second_error);
+  assert_equals_serialized_message_error_event(
+    serialized_second_error, expected_origin, expected_has_source);
+}
+
+// Performs the send message error test followed by the receive message error
+// test.
+async function do_send_and_receive_message_error_test(
+  test,
+  root_dir,
+  receiver,
+  target,
+  target_origin,
+  // False when the MessageEvent's source is null.
+  expected_has_source,
+  // The origin of MessageEvents received by |target|.
+  expected_origin,
+  // The origin of MessageEvents received by this test runner.
+  expected_remote_origin) {
+  await do_send_message_error_test(
+    test, root_dir, receiver, target, target_origin, expected_has_source,
+    expected_origin);
+  await do_receive_message_error_test(
+    test, receiver, target, target_origin, expected_has_source,
+    expected_remote_origin);
+}
+
+// Runs the same test as do_send_message_error_test(), but uses a MessagePort.
+// This test starts by establishing a message channel between the test runner
+// and |target|.
+async function do_send_message_port_error_test(
+  test, root_dir, target, target_origin) {
+  const message_port = create_message_channel(target, target_origin);
+  await do_send_message_error_test(
+    test, root_dir, /*receiver=*/message_port, /*target=*/message_port,
+    /*target_origin=*/undefined, /*expected_has_source=*/false,
+    /*expected_origin=*/'', /*expected_remote_origin=*/'');
+}
+
+// Runs the same test as do_receive_message_error_test(), but uses a MessagePort.
+async function do_receive_message_port_error_test(
+  test, target, target_origin) {
+  const message_port = create_message_channel(target, target_origin);
+  await do_receive_message_error_test(
+    test, /*receiver=*/message_port, /*target=*/message_port,
+    /*target_origin=*/undefined, /*expected_has_source=*/false,
+    /*expected_origin=*/'');
+}
+
+// Runs the same test as do_send_and_receive_message_error_test(), but uses a
+// MessagePort.
+async function do_send_and_receive_message_port_error_test(
+  test, root_dir, target, target_origin) {
+  await do_send_message_port_error_test(
+    test, root_dir, target, target_origin);
+  await do_receive_message_port_error_test(
+    test, target, target_origin);
+}
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(
+    t, { src: kRemoteOriginDocumentMessageTarget });
+  await do_send_and_receive_message_error_test(
+    t, root_dir, /*receiver=*/self, /*target=*/iframe.contentWindow,
+    /*target_origin=*/'*', /*expected_has_source=*/true,
+    /*expected_origin=*/location.origin,
+    /*expected_remote_origin=*/kRemoteOrigin);
+}, 'Fail to send and receive messages using a cross origin iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(t, { src: kRemoteOriginDocumentMessageTarget });
+  await do_send_and_receive_message_port_error_test(
+    t, root_dir, /*target=*/iframe.contentWindow, /*target_origin=*/'*');
+}, 'Fail to send and receive messages using a cross origin message port in ' +
+'an iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(
+    t, { src: kDocumentMessageTarget, sandbox: 'allow-scripts' });
+
+  await do_send_message_error_test(
+    t, root_dir, /*receiver=*/self, /*target=*/iframe.contentWindow,
+    /*target_origin=*/'*', /*expected_has_source*/true,
+    /*expected_origin=*/location.origin);
+}, 'Fail to send to a sandboxed iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(
+    t, { src: kDocumentMessageTarget, sandbox: 'allow-scripts' });
+  await do_send_message_port_error_test(
+    t, root_dir, /*target=*/iframe.contentWindow, /*target_origin=*/'*');
+}, 'Fail to send messages using a message port to a sandboxed ' +
+'iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe_data_uri = await create_message_target_data_uri(t);
+  const iframe = await add_iframe(t, { src: iframe_data_uri });
+  await do_send_message_error_test(t, root_dir, /*receiver=*/self,
+    /*target=*/iframe.contentWindow, /*target_origin=*/'*',
+    /*expected_has_source*/true, /*expected_origin=*/location.origin);
+  // Do not test receiving FileSystemHandles from the data URI iframe. Data URI
+  // iframes are insecure and do not expose the File System Access APIs.
+}, 'Fail to send messages to a data URI iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe_data_uri = await create_message_target_data_uri(t);
+  const iframe = await add_iframe(t, { src: iframe_data_uri });
+  await do_send_message_port_error_test(
+    t, root_dir, /*target=*/iframe.contentWindow, /*target_origin=*/'*');
+}, 'Fail to send messages using a message port in a data URI iframe.');
+
+directory_test(async (t, root_dir) => {
+  const child_window = await open_window(t, kRemoteOriginDocumentMessageTarget);
+  await do_send_and_receive_message_error_test(
+    t, root_dir, /*receiver=*/self, /*target=*/child_window, /*target_origin=*/'*',
+    /*expected_has_source=*/true, /*expected_origin=*/location.origin,
+    /*expected_remote_origin=*/kRemoteOrigin);
+}, 'Fail to send and receive messages using a cross origin window.');
+
+directory_test(async (t, root_dir) => {
+  const child_window = await open_window(t, kRemoteOriginDocumentMessageTarget);
+  await do_send_message_port_error_test(
+    t, root_dir, /*target=*/child_window, /*target_origin=*/'*');
+}, 'Fail to send and receive messages using a cross origin message port in ' +
+'a window.');
+
+directory_test(async (t, root_dir) => {
+  const url = `${kDocumentMessageTarget}?pipe=header(Content-Security-Policy` +
+    ', sandbox allow-scripts)';
+  const child_window = await open_window(t, url);
+  await do_send_message_error_test(
+    t, root_dir, /*receiver=*/self, /*target=*/child_window,
+    /*target_origin=*/'*', /*expected_has_source*/true,
+    /*expected_origin=*/location.origin);
+}, 'Fail to send messages to  a sandboxed window.');
+
+directory_test(async (t, root_dir) => {
+  const url = `${kDocumentMessageTarget}?pipe=header(Content-Security-Policy` +
+    ', sandbox allow-scripts)';
+  const child_window = await open_window(t, url);
+  await do_send_message_port_error_test(
+    t, root_dir, /*target=*/child_window, /*target_origin=*/'*');
+}, 'Fail to send messages using a message port to a sandboxed ' +
+'window.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortframesjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,44 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+directory_test(
+    async (t, root_dir) => {
+      const iframe = await add_iframe(t, {src: kDocumentMessageTarget});
+      await do_message_port_test(
+          t, root_dir, /*target=*/ iframe.contentWindow,
+          /*target_origin=*/ '*');
+    },
+    'Send and receive messages using a message port in a same origin ' +
+        'iframe.');
+
+directory_test(
+    async (t, root_dir) => {
+      const iframe = await add_iframe(t, {
+        src: kDocumentMessageTarget,
+        sandbox: 'allow-scripts allow-same-origin'
+      });
+      await do_message_port_test(
+          t, root_dir, /*target=*/ iframe.contentWindow,
+          /*target_origin=*/ '*');
+    },
+    'Send and receive messages using a message port in a sandboxed same ' +
+        'origin iframe.');
+
+directory_test(async (t, root_dir) => {
+  const blob_url = await create_message_target_blob_url(t);
+  const iframe = await add_iframe(t, {src: blob_url});
+  await do_message_port_test(
+      t, root_dir, /*target=*/ iframe.contentWindow, /*target_origin=*/ '*');
+}, 'Send and receive messages using a message port in a blob iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe_html = await create_message_target_html_without_subresources(t);
+  const iframe = await add_iframe(t, {srcdoc: iframe_html});
+  await do_message_port_test(
+      t, root_dir, /*target=*/ iframe.contentWindow, /*target_origin=*/ '*');
+}, 'Send and receive messages using a message port in an iframe srcdoc.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortwindowsjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,35 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+directory_test(
+    async (t, root_dir) => {
+      const child_window = await open_window(t, kDocumentMessageTarget);
+      await do_message_port_test(
+          t, root_dir, /*target=*/ child_window, /*target_origin=*/ '*');
+    },
+    'Send and receive messages using a message port in a same origin ' +
+        'window.');
+
+directory_test(async (t, root_dir) => {
+  const blob_url = await create_message_target_blob_url(t);
+  const child_window = await open_window(t, blob_url);
+  await do_message_port_test(
+      t, root_dir, /*target=*/ child_window, /*target_origin=*/ '*');
+}, 'Send and receive messages using a message port in a blob window.');
+
+directory_test(
+    async (t, root_dir) => {
+      const url =
+          `${kDocumentMessageTarget}?pipe=header(Content-Security-Policy` +
+          ', sandbox allow-scripts allow-same-origin)';
+      const child_window = await open_window(t, url);
+      await do_message_port_test(
+          t, root_dir, /*target=*/ child_window, /*target_origin=*/ '*');
+    },
+    'Send and receive messages using a message port in a sandboxed same ' +
+        'origin window.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageMessagePortworkersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,40 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+//    /service-workers/service-worker/resources/test-helpers.sub.js
+
+directory_test(
+    async (t, root_dir) => {
+      const dedicated_worker =
+          create_dedicated_worker(t, kDedicatedWorkerMessageTarget);
+      await do_message_port_test(t, root_dir, /*target=*/ dedicated_worker);
+    },
+    'Send and receive messages using a message port in a dedicated ' +
+        'worker.');
+
+directory_test(
+    async (t, root_dir) => {
+      const scope = `${kServiceWorkerMessageTarget}` +
+          '?post-message-to-message-port-with-file-handle';
+      const registration =
+          await create_service_worker(t, kServiceWorkerMessageTarget, scope);
+      await do_message_port_test(
+          t, root_dir, /*target=*/ registration.installing);
+    },
+    'Send and receive messages using a message port in a service ' +
+        'worker.');
+
+if (self.SharedWorker !== undefined) {
+  directory_test(
+      async (t, root_dir) => {
+        const shared_worker = new SharedWorker(kSharedWorkerMessageTarget);
+        shared_worker.port.start();
+        await do_message_port_test(t, root_dir, /*target=*/ shared_worker.port);
+      },
+      'Send and receive messages using a message port in a shared ' +
+          ' worker.');
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageframesjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,40 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(t, {src: kDocumentMessageTarget});
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ iframe.contentWindow,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a same origin iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe = await add_iframe(t, {
+    src: kDocumentMessageTarget,
+    sandbox: 'allow-scripts allow-same-origin'
+  });
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ iframe.contentWindow,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a sandboxed same origin iframe.');
+
+directory_test(async (t, root_dir) => {
+  const blob_url = await create_message_target_blob_url(t);
+  const iframe = await add_iframe(t, {src: blob_url});
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ iframe.contentWindow,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a blob iframe.');
+
+directory_test(async (t, root_dir) => {
+  const iframe_html = await create_message_target_html_without_subresources(t);
+  const iframe = await add_iframe(t, {srcdoc: iframe_html});
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ iframe.contentWindow,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using an iframe srcdoc.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessagewindowsjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+directory_test(async (t, root_dir) => {
+  const child_window = await open_window(t, kDocumentMessageTarget);
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ child_window,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a same origin window.');
+
+directory_test(async (t, root_dir) => {
+  const blob_url = await create_message_target_blob_url(t);
+  const child_window = await open_window(t, blob_url);
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ child_window,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a blob window.');
+
+directory_test(async (t, root_dir) => {
+  const url = `${kDocumentMessageTarget}?pipe=header(Content-Security-Policy` +
+      ', sandbox allow-scripts allow-same-origin)';
+  const child_window = await open_window(t, url);
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ self, /*target=*/ child_window,
+      /*target_origin=*/ '*');
+}, 'Send and receive messages using a sandboxed same origin window.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandlepostMessageworkersjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,35 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/messaging-blob-helpers.js
+//    /file-system-access/resources/messaging-serialize-helpers.js
+//    /file-system-access/resources/test-helpers.js
+//    /service-workers/service-worker/resources/test-helpers.sub.js
+
+directory_test(async (t, root_dir) => {
+  const dedicated_worker =
+      create_dedicated_worker(t, kDedicatedWorkerMessageTarget);
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ dedicated_worker,
+      /*target=*/ dedicated_worker);
+}, 'Send and receive messages using a dedicated worker.');
+
+directory_test(async (t, root_dir) => {
+  const scope = `${kServiceWorkerMessageTarget}?post-message-with-file-handle`;
+  const registration =
+      await create_service_worker(t, kServiceWorkerMessageTarget, scope);
+  await do_post_message_test(
+      t, root_dir, /*receiver=*/ navigator.serviceWorker,
+      /*target=*/ registration.installing);
+}, 'Send and receive messages using a service worker.');
+
+if (self.SharedWorker !== undefined) {
+  directory_test(async (t, root_dir) => {
+    const shared_worker = new SharedWorker(kSharedWorkerMessageTarget);
+    shared_worker.port.start();
+    await do_post_message_test(
+        t, root_dir, /*receiver=*/ shared_worker.port,
+        /*target=*/ shared_worker.port);
+  }, 'Send and receive messages using a shared worker.');
+}
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemBaseHandleremovejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,75 @@
</span><ins>+'use strict';
+
+directory_test(async (t, root) => {
+  const handle =
+      await createFileWithContents(t, 'file-to-remove', '12345', root);
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await handle.remove();
+
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+  await promise_rejects_dom(t, 'NotFoundError', getFileContents(handle));
+}, 'remove() to remove a file');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createFileWithContents(t, 'file-to-remove', '12345', root);
+  await handle.remove();
+
+  await promise_rejects_dom(t, 'NotFoundError', handle.remove());
+}, 'remove() on an already removed file should fail');
+
+directory_test(async (t, root) => {
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await dir.remove();
+
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+  await promise_rejects_dom(t, 'NotFoundError', getSortedDirectoryEntries(dir));
+}, 'remove() to remove an empty directory');
+
+directory_test(async (t, root) => {
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  await dir.remove();
+
+  await promise_rejects_dom(t, 'NotFoundError', dir.remove());
+}, 'remove() on an already removed directory should fail');
+
+directory_test(async (t, root) => {
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  t.add_cleanup(() => root.removeEntry('dir-to-remove', {recursive: true}));
+  await createEmptyFile(t, 'file-in-dir', dir);
+
+  await promise_rejects_dom(t, 'InvalidModificationError', dir.remove());
+  assert_array_equals(
+      await getSortedDirectoryEntries(root), ['dir-to-remove/']);
+  assert_array_equals(await getSortedDirectoryEntries(dir), ['file-in-dir']);
+}, 'remove() on a non-empty directory should fail');
+
+directory_test(async (t, root) => {
+  // root
+  // ├──file-to-keep
+  // ├──dir-to-remove
+  //    ├── file0
+  //    ├── dir1-in-dir
+  //    │   └── file1
+  //    └── dir2
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await createEmptyFile(t, 'file0', dir);
+  const dir1_in_dir = await createDirectory(t, 'dir1-in-dir', dir);
+  await createEmptyFile(t, 'file1', dir1_in_dir);
+  await createDirectory(t, 'dir2-in-dir', dir);
+
+  await dir.remove({recursive: true});
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+}, 'remove() on a directory recursively should delete all sub-items');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createFileWithContents(t, 'file-to-remove', '12345', root);
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await handle.remove({recursive: true});
+
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+  await promise_rejects_dom(t, 'NotFoundError', getFileContents(handle));
+}, 'remove() on a file should ignore the recursive option');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandlegetDirectoryHandlejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,115 @@
</span><ins>+directory_test(async (t, root) => {
+  await promise_rejects_dom(
+      t, 'NotFoundError', root.getDirectoryHandle('non-existing-dir'));
+}, 'getDirectoryHandle(create=false) rejects for non-existing directories');
+
+directory_test(async (t, root) => {
+  const handle =
+      await root.getDirectoryHandle('non-existing-dir', {create: true});
+  t.add_cleanup(() => root.removeEntry('non-existing-dir', {recursive: true}));
+
+  assert_equals(handle.kind, 'directory');
+  assert_equals(handle.name, 'non-existing-dir');
+  assert_equals(await getDirectoryEntryCount(handle), 0);
+  assert_array_equals(
+      await getSortedDirectoryEntries(root), ['non-existing-dir/']);
+}, 'getDirectoryHandle(create=true) creates an empty directory');
+
+directory_test(async (t, root) => {
+  const existing_handle =
+      await root.getDirectoryHandle('dir-with-contents', {create: true});
+  t.add_cleanup(() => root.removeEntry('dir-with-contents', {recursive: true}));
+  const file_handle = await createEmptyFile(t, 'test-file', existing_handle);
+
+  const handle =
+      await root.getDirectoryHandle('dir-with-contents', {create: false});
+
+  assert_equals(handle.kind, 'directory');
+  assert_equals(handle.name, 'dir-with-contents');
+  assert_array_equals(await getSortedDirectoryEntries(handle), ['test-file']);
+}, 'getDirectoryHandle(create=false) returns existing directories');
+
+directory_test(async (t, root) => {
+  const existing_handle =
+      await root.getDirectoryHandle('dir-with-contents', {create: true});
+  t.add_cleanup(() => root.removeEntry('dir-with-contents', {recursive: true}));
+  const file_handle =
+      await existing_handle.getFileHandle('test-file', {create: true});
+
+  const handle =
+      await root.getDirectoryHandle('dir-with-contents', {create: true});
+
+  assert_equals(handle.kind, 'directory');
+  assert_equals(handle.name, 'dir-with-contents');
+  assert_array_equals(await getSortedDirectoryEntries(handle), ['test-file']);
+}, 'getDirectoryHandle(create=true) returns existing directories without erasing');
+
+directory_test(async (t, root) => {
+  await createEmptyFile(t, 'file-name', root);
+
+  await promise_rejects_dom(
+      t, 'TypeMismatchError', root.getDirectoryHandle('file-name'));
+  await promise_rejects_dom(
+      t, 'TypeMismatchError',
+      root.getDirectoryHandle('file-name', {create: false}));
+  await promise_rejects_dom(
+      t, 'TypeMismatchError',
+      root.getDirectoryHandle('file-name', {create: true}));
+}, 'getDirectoryHandle() when a file already exists with the same name');
+
+directory_test(async (t, dir) => {
+  await promise_rejects_js(
+      t, TypeError, dir.getDirectoryHandle('', {create: true}));
+  await promise_rejects_js(
+      t, TypeError, dir.getDirectoryHandle('', {create: false}));
+}, 'getDirectoryHandle() with empty name');
+
+directory_test(async (t, dir) => {
+  await promise_rejects_js(
+      t, TypeError, dir.getDirectoryHandle(kCurrentDirectory));
+  await promise_rejects_js(
+      t, TypeError, dir.getDirectoryHandle(kCurrentDirectory, {create: true}));
+}, `getDirectoryHandle() with "${kCurrentDirectory}" name`);
+
+directory_test(async (t, dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', /*parent=*/ dir);
+
+  await promise_rejects_js(
+      t, TypeError, subdir.getDirectoryHandle(kParentDirectory));
+  await promise_rejects_js(
+      t, TypeError,
+      subdir.getDirectoryHandle(kParentDirectory, {create: true}));
+}, `getDirectoryHandle() with "${kParentDirectory}" name`);
+
+directory_test(async (t, dir) => {
+  const first_subdir_name = 'first-subdir-name';
+  const first_subdir =
+      await createDirectory(t, first_subdir_name, /*parent=*/ dir);
+
+  const second_subdir_name = 'second-subdir-name';
+  const second_subdir =
+      await createDirectory(t, second_subdir_name, /*parent=*/ first_subdir);
+
+  for (let i = 0; i < kPathSeparators.length; ++i) {
+    const path_with_separator =
+        `${first_subdir_name}${kPathSeparators[i]}${second_subdir_name}`;
+    await promise_rejects_js(
+        t, TypeError, dir.getDirectoryHandle(path_with_separator),
+        `getDirectoryHandle() must reject names containing "${
+            kPathSeparators[i]}"`);
+  }
+}, 'getDirectoryHandle(create=false) with a path separator when the directory exists');
+
+directory_test(async (t, dir) => {
+  const subdir_name = 'subdir-name';
+  const subdir = await createDirectory(t, subdir_name, /*parent=*/ dir);
+
+  for (let i = 0; i < kPathSeparators.length; ++i) {
+    const path_with_separator = `${subdir_name}${kPathSeparators[i]}file_name`;
+    await promise_rejects_js(
+        t, TypeError,
+        dir.getDirectoryHandle(path_with_separator, {create: true}),
+        `getDirectoryHandle(true) must reject names containing "${
+            kPathSeparators[i]}"`);
+  }
+}, 'getDirectoryHandle(create=true) with a path separator');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandlegetFileHandlejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,102 @@
</span><ins>+directory_test(async (t, dir) => {
+  await promise_rejects_dom(
+      t, 'NotFoundError', dir.getFileHandle('non-existing-file'));
+}, 'getFileHandle(create=false) rejects for non-existing files');
+
+directory_test(async (t, dir) => {
+  const handle = await dir.getFileHandle('non-existing-file', {create: true});
+  t.add_cleanup(() => dir.removeEntry('non-existing-file'));
+
+  assert_equals(handle.kind, 'file');
+  assert_equals(handle.name, 'non-existing-file');
+  assert_equals(await getFileSize(handle), 0);
+  assert_equals(await getFileContents(handle), '');
+}, 'getFileHandle(create=true) creates an empty file for non-existing files');
+
+directory_test(async (t, dir) => {
+  const existing_handle = await createFileWithContents(
+      t, 'existing-file', '1234567890', /*parent=*/ dir);
+  const handle = await dir.getFileHandle('existing-file');
+
+  assert_equals(handle.kind, 'file');
+  assert_equals(handle.name, 'existing-file');
+  assert_equals(await getFileSize(handle), 10);
+  assert_equals(await getFileContents(handle), '1234567890');
+}, 'getFileHandle(create=false) returns existing files');
+
+directory_test(async (t, dir) => {
+  const existing_handle = await createFileWithContents(
+      t, 'file-with-contents', '1234567890', /*parent=*/ dir);
+  const handle = await dir.getFileHandle('file-with-contents', {create: true});
+
+  assert_equals(handle.kind, 'file');
+  assert_equals(handle.name, 'file-with-contents');
+  assert_equals(await getFileSize(handle), 10);
+  assert_equals(await getFileContents(handle), '1234567890');
+}, 'getFileHandle(create=true) returns existing files without erasing');
+
+directory_test(async (t, dir) => {
+  const dir_handle = await dir.getDirectoryHandle('dir-name', {create: true});
+  t.add_cleanup(() => dir.removeEntry('dir-name', {recursive: true}));
+
+  await promise_rejects_dom(
+      t, 'TypeMismatchError', dir.getFileHandle('dir-name'));
+}, 'getFileHandle(create=false) when a directory already exists with the same name');
+
+directory_test(async (t, dir) => {
+  const dir_handle = await dir.getDirectoryHandle('dir-name', {create: true});
+  t.add_cleanup(() => dir.removeEntry('dir-name', {recursive: true}));
+
+  await promise_rejects_dom(
+      t, 'TypeMismatchError', dir.getFileHandle('dir-name', {create: true}));
+}, 'getFileHandle(create=true) when a directory already exists with the same name');
+
+directory_test(async (t, dir) => {
+  await promise_rejects_js(t, TypeError, dir.getFileHandle('', {create: true}));
+  await promise_rejects_js(
+      t, TypeError, dir.getFileHandle('', {create: false}));
+}, 'getFileHandle() with empty name');
+
+directory_test(async (t, dir) => {
+  await promise_rejects_js(t, TypeError, dir.getFileHandle(kCurrentDirectory));
+  await promise_rejects_js(
+      t, TypeError, dir.getFileHandle(kCurrentDirectory, {create: true}));
+}, `getFileHandle() with "${kCurrentDirectory}" name`);
+
+directory_test(async (t, dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', /*parent=*/ dir);
+
+  await promise_rejects_js(
+      t, TypeError, subdir.getFileHandle(kParentDirectory));
+  await promise_rejects_js(
+      t, TypeError, subdir.getFileHandle(kParentDirectory, {create: true}));
+}, `getFileHandle() with "${kParentDirectory}" name`);
+
+directory_test(async (t, dir) => {
+  const subdir_name = 'subdir-name';
+  const subdir = await createDirectory(t, subdir_name, /*parent=*/ dir);
+
+  const file_name = 'file-name';
+  await createEmptyFile(t, file_name, /*parent=*/ subdir);
+
+  for (let i = 0; i < kPathSeparators.length; ++i) {
+    const path_with_separator =
+        `${subdir_name}${kPathSeparators[i]}${file_name}`;
+    await promise_rejects_js(
+        t, TypeError, dir.getFileHandle(path_with_separator),
+        `getFileHandle() must reject names containing "${kPathSeparators[i]}"`);
+  }
+}, 'getFileHandle(create=false) with a path separator when the file exists.');
+
+directory_test(async (t, dir) => {
+  const subdir_name = 'subdir-name';
+  const subdir = await createDirectory(t, subdir_name, /*parent=*/ dir);
+
+  for (let i = 0; i < kPathSeparators.length; ++i) {
+    const path_with_separator = `${subdir_name}${kPathSeparators[i]}file_name`;
+    await promise_rejects_js(
+        t, TypeError, dir.getFileHandle(path_with_separator, {create: true}),
+        `getFileHandle(create=true) must reject names containing "${
+            kPathSeparators[i]}"`);
+  }
+}, 'getFileHandle(create=true) with a path separator');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleiterationjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,98 @@
</span><ins>+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  const file_name2 = 'foo2.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+  await createFileWithContents(t, file_name2, 'contents', /*parent=*/ root);
+
+  for await (let entry of root) {
+    break;
+  }
+
+}, 'returning early from an iteration doesn\'t crash');
+
+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  const file_name2 = 'foo2.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+  await createFileWithContents(t, file_name2, 'contents', /*parent=*/ root);
+
+  let names = [];
+  for await (let entry of root) {
+    assert_true(Array.isArray(entry));
+    assert_equals(entry.length, 2);
+    assert_equals(typeof entry[0], 'string');
+    assert_true(entry[1] instanceof FileSystemFileHandle);
+    assert_equals(entry[0], entry[1].name);
+    names.push(entry[0]);
+  }
+  names.sort();
+  assert_array_equals(names, [file_name1, file_name2]);
+
+}, '@@asyncIterator: full iteration works');
+
+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  const file_name2 = 'foo2.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+  await createFileWithContents(t, file_name2, 'contents', /*parent=*/ root);
+
+  let names = [];
+  for await (let entry of root.entries()) {
+    assert_true(Array.isArray(entry));
+    assert_equals(entry.length, 2);
+    assert_equals(typeof entry[0], 'string');
+    assert_true(entry[1] instanceof FileSystemFileHandle);
+    assert_equals(entry[0], entry[1].name);
+    names.push(entry[0]);
+  }
+  names.sort();
+  assert_array_equals(names, [file_name1, file_name2]);
+}, 'entries: full iteration works');
+
+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  const file_name2 = 'foo2.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+  await createFileWithContents(t, file_name2, 'contents', /*parent=*/ root);
+
+  let names = [];
+  for await (let entry of root.values()) {
+    assert_true(entry instanceof FileSystemFileHandle);
+    names.push(entry.name);
+  }
+  names.sort();
+  assert_array_equals(names, [file_name1, file_name2]);
+}, 'values: full iteration works');
+
+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  const file_name2 = 'foo2.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+  await createFileWithContents(t, file_name2, 'contents', /*parent=*/ root);
+
+  let names = [];
+  for await (let entry of root.keys()) {
+    assert_equals(typeof entry, 'string');
+    names.push(entry);
+  }
+  names.sort();
+  assert_array_equals(names, [file_name1, file_name2]);
+}, 'keys: full iteration works');
+
+directory_test(async (t, root) => {
+  const file_name1 = 'foo1.txt';
+  await createFileWithContents(t, file_name1, 'contents', /*parent=*/ root);
+
+  const next = (() => {
+    const iterator = root.entries();
+    return iterator.next();
+  })();
+  garbageCollect();
+  let entry = await next;
+  assert_false(entry.done);
+  assert_true(Array.isArray(entry.value));
+  assert_equals(entry.value.length, 2);
+  assert_equals(entry.value[0], file_name1);
+  assert_true(entry.value[1] instanceof FileSystemFileHandle);
+  assert_equals(entry.value[1].name, file_name1);
+}, 'iteration while iterator gets garbage collected');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleremoveEntryjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js                               (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js  2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,88 @@
</span><ins>+
+directory_test(async (t, root) => {
+  const handle =
+      await createFileWithContents(t, 'file-to-remove', '12345', root);
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await root.removeEntry('file-to-remove');
+
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+  await promise_rejects_dom(t, 'NotFoundError', getFileContents(handle));
+}, 'removeEntry() to remove a file');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createFileWithContents(t, 'file-to-remove', '12345', root);
+  await root.removeEntry('file-to-remove');
+
+  await promise_rejects_dom(t, 'NotFoundError', root.removeEntry('file-to-remove'));
+}, 'removeEntry() on an already removed file should fail');
+
+directory_test(async (t, root) => {
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await root.removeEntry('dir-to-remove');
+
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+  await promise_rejects_dom(t, 'NotFoundError', getSortedDirectoryEntries(dir));
+}, 'removeEntry() to remove an empty directory');
+
+directory_test(async (t, root) => {
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  t.add_cleanup(() => root.removeEntry('dir-to-remove', {recursive: true}));
+  await createEmptyFile(t, 'file-in-dir', dir);
+
+  await promise_rejects_dom(
+      t, 'InvalidModificationError', root.removeEntry('dir-to-remove'));
+  assert_array_equals(
+      await getSortedDirectoryEntries(root), ['dir-to-remove/']);
+  assert_array_equals(await getSortedDirectoryEntries(dir), ['file-in-dir']);
+}, 'removeEntry() on a non-empty directory should fail');
+
+directory_test(async (t, root) => {
+  // root
+  // ├──file-to-keep
+  // ├──dir-to-remove
+  //    ├── file0
+  //    ├── dir1-in-dir
+  //    │   └── file1
+  //    └── dir2
+  const dir = await root.getDirectoryHandle('dir-to-remove', {create: true});
+  await createFileWithContents(t, 'file-to-keep', 'abc', root);
+  await createEmptyFile(t, 'file0', dir);
+  const dir1_in_dir = await createDirectory(t, 'dir1-in-dir', dir);
+  await createEmptyFile(t, 'file1', dir1_in_dir);
+  await createDirectory(t, 'dir2-in-dir', dir);
+
+  await root.removeEntry('dir-to-remove', {recursive: true});
+  assert_array_equals(await getSortedDirectoryEntries(root), ['file-to-keep']);
+}, 'removeEntry() on a directory recursively should delete all sub-items');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'dir', root);
+  await promise_rejects_js(t, TypeError, dir.removeEntry(''));
+}, 'removeEntry() with empty name should fail');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'dir', root);
+  await promise_rejects_js(t, TypeError, dir.removeEntry(kCurrentDirectory));
+}, `removeEntry() with "${kCurrentDirectory}" name should fail`);
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'dir', root);
+  await promise_rejects_js(t, TypeError, dir.removeEntry(kParentDirectory));
+}, `removeEntry() with "${kParentDirectory}" name should fail`);
+
+directory_test(async (t, root) => {
+  const dir_name = 'dir-name';
+  const dir = await createDirectory(t, dir_name, root);
+
+  const file_name = 'file-name';
+  await createEmptyFile(t, file_name, dir);
+
+  for (let i = 0; i < kPathSeparators.length; ++i) {
+    const path_with_separator = `${dir_name}${kPathSeparators[i]}${file_name}`;
+    await promise_rejects_js(
+        t, TypeError, root.removeEntry(path_with_separator),
+        `removeEntry() must reject names containing "${kPathSeparators[i]}"`);
+  }
+}, 'removeEntry() with a path separator should fail.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemDirectoryHandleresolvejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,27 @@
</span><ins>+'use strict';
+
+directory_test(async (t, root_dir) => {
+  assert_array_equals(await root_dir.resolve(root_dir), []);
+}, 'Resolve returns empty array for same directory');
+
+directory_test(async (t, root_dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+  const file = await createEmptyFile(t, 'file-name', subdir);
+
+  assert_array_equals(await root_dir.resolve(file), ['subdir-name', 'file-name']);
+}, 'Resolve returns correct path');
+
+directory_test(async (t, root_dir) => {
+  const subdir = await createDirectory(t, 'subdir😊', root_dir);
+  const file = await createEmptyFile(t, 'file-name', subdir);
+
+  assert_array_equals(await root_dir.resolve(file), ['subdir😊', 'file-name']);
+  assert_array_equals(await root_dir.resolve(subdir), ['subdir😊']);
+}, 'Resolve returns correct path with non-ascii characters');
+
+directory_test(async (t, root_dir) => {
+  const subdir = await createDirectory(t, 'subdir-name', root_dir);
+  const file = await createEmptyFile(t, 'file-name', root_dir);
+
+  assert_equals(await subdir.resolve(file), null);
+}, 'Resolve returns null when entry is not a child');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemFileHandlecreatesyncaccesshandlededicatedworkerjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js                             (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js        2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,26 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+//    /file-system-access/resources/test-helpers.js
+
+directory_test(async (t, root_dir) => {
+  assert_true(
+      file_system_type == 'sandboxed' || file_system_type == 'local',
+      'File system type should be sandboxed or local.');
+  const expect_success = file_system_type == 'sandboxed';
+
+  const dedicated_worker =
+      create_dedicated_worker(t, kDedicatedWorkerMessageTarget);
+  const file_handle =
+      await root_dir.getFileHandle('sync-access-handle-file', {create: true});
+
+  dedicated_worker.postMessage(
+      {type: 'create-sync-access-handle', file_handle});
+
+  const event_watcher = new EventWatcher(t, dedicated_worker, 'message');
+  const message_event = await event_watcher.wait_for('message');
+  const response = message_event.data;
+
+  assert_equals(response.success, expect_success);
+}, 'Attempt to create a sync access handle.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemFileHandlegetFilejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,40 @@
</span><ins>+directory_test(async (t, root) => {
+  const fileContents = 'awesome content';
+  let handle = await createFileWithContents(t, 'foo.txt', fileContents, /*parent=*/ root);
+  let file = await handle.getFile();
+  let slice = file.slice(1, file.size);
+  let actualContents = await slice.text();
+  assert_equals(actualContents, fileContents.slice(1, fileContents.length));
+}, 'getFile() provides a file that can be sliced');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'mtime.txt', root);
+  let file = await handle.getFile();
+  const first_mtime = file.lastModified;
+
+  // We wait for 2s here to ensure that the files do not have the
+  // same modification time. Some filesystems have low resolutions
+  // for modification timestamps.
+  let timeout = new Promise(resolve => {
+    t.step_timeout(resolve, 2000);
+  });
+  await timeout;
+
+  const writer = await handle.createWritable({keepExistingData: false});
+  await writer.write(new Blob(['foo']));
+  await writer.close();
+
+  file = await handle.getFile();
+  const second_mtime = file.lastModified;
+
+  // We wait for 5 ms here to ensure that `lastModified`
+  // from the File objects is stable between getFile invocations.
+  timeout = new Promise(resolve => {
+    t.step_timeout(resolve, 5);
+  });
+  await timeout;
+  let fileReplica = await handle.getFile();
+  assert_equals(second_mtime, fileReplica.lastModified);
+
+  assert_less_than(first_mtime, second_mtime);
+}, 'getFile() returns last modified time');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemSyncAccessHandleflushjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js                            (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js       2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,8 @@
</span><ins>+'use strict';
+
+// This script depends on the following scripts:
+//    /file-system-access/resources/messaging-helpers.js
+
+sync_access_handle_test(async handle => {
+  await handle.flush();
+}, 'Test flush on an empty file.');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreampipedjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,135 @@
</span><ins>+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_string.txt', root);
+  const wfs = await handle.createWritable();
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue('foo_string');
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'foo_string');
+  assert_equals(await getFileSize(handle), 10);
+}, 'can be piped to with a string');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_arraybuf.txt', root);
+  const wfs = await handle.createWritable();
+  const buf = new ArrayBuffer(3);
+  const intView = new Uint8Array(buf);
+  intView[0] = 0x66;
+  intView[1] = 0x6f;
+  intView[2] = 0x6f;
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue(buf);
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+}, 'can be piped to with an ArrayBuffer');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_blob.txt', root);
+  const wfs = await handle.createWritable();
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue(new Blob(['foo']));
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+}, 'can be piped to with a Blob');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_write_param.txt', root);
+  const wfs = await handle.createWritable();
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue({type: 'write', data: 'foobar'});
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'foobar');
+  assert_equals(await getFileSize(handle), 6);
+}, 'can be piped to with a param object with write command');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_write_param.txt', root);
+  const wfs = await handle.createWritable();
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue({type: 'write', data: 'foobar'});
+      controller.enqueue({type: 'truncate', size: 10});
+      controller.enqueue({type: 'write', position: 0, data: 'baz'});
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'bazbar\0\0\0\0');
+  assert_equals(await getFileSize(handle), 10);
+}, 'can be piped to with a param object with multiple commands');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'foo_write_queued.txt', root);
+  const wfs = await handle.createWritable();
+
+  const rs = recordingReadableStream({
+    start(controller) {
+      controller.enqueue('foo');
+      controller.enqueue('bar');
+      controller.enqueue('baz');
+      controller.close();
+    }
+  });
+
+  await rs.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'foobarbaz');
+  assert_equals(await getFileSize(handle), 9);
+}, 'multiple operations can be queued');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'fetched.txt', root);
+  const wfs = await handle.createWritable();
+
+  const response = await fetch('data:text/plain,fetched from far');
+  const body = await response.body;
+  await body.pipeTo(wfs, { preventCancel: true });
+  assert_equals(await getFileContents(handle), 'fetched from far');
+  assert_equals(await getFileSize(handle), 16);
+}, 'plays well with fetch');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'aborted should_be_empty.txt', root);
+  const wfs = await handle.createWritable();
+
+  const response = await fetch('data:text/plain,fetched from far');
+  const body = await response.body;
+
+  const abortController = new AbortController();
+  const signal = abortController.signal;
+
+  const promise = body.pipeTo(wfs, { signal });
+  await abortController.abort();
+
+  await promise_rejects_dom(t, 'AbortError', promise, 'stream is aborted');
+  await promise_rejects_js(t, TypeError, wfs.close(), 'stream cannot be closed to flush writes');
+
+  assert_equals(await getFileContents(handle), '');
+  assert_equals(await getFileSize(handle), 0);
+}, 'abort() aborts write');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreamwritejs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js                          (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js     2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,352 @@
</span><ins>+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'empty_blob', root);
+  const stream = await handle.createWritable();
+
+  await stream.write(new Blob([]));
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '');
+  assert_equals(await getFileSize(handle), 0);
+}, 'write() with an empty blob to an empty file');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'valid_blob', root);
+  const stream = await handle.createWritable();
+
+  await stream.write(new Blob(['1234567890']));
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() a blob to an empty file');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'write_param_empty', root);
+  const stream = await handle.createWritable();
+
+  await stream.write({type: 'write', data: '1234567890'});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() with WriteParams without position to an empty file');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'string_zero_offset', root);
+  const stream = await handle.createWritable();
+
+  await stream.write({type: 'write', position: 0, data: '1234567890'});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() a string to an empty file with zero offset');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'blob_zero_offset', root);
+  const stream = await handle.createWritable();
+
+  await stream.write({type: 'write', position: 0, data: new Blob(['1234567890'])});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() a blob to an empty file with zero offset');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'write_appends', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('12345');
+  await stream.write('67890');
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() called consecutively appends');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'write_appends_object_string', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('12345');
+  await stream.write({type: 'write', data: '67890'});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() WriteParams without position and string appends');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'write_appends_object_blob', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('12345');
+  await stream.write({type: 'write', data: new Blob(['67890'])});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234567890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() WriteParams without position and blob appends');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'string_with_offset', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('1234567890');
+  await stream.write({type: 'write', position: 4, data: 'abc'});
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '1234abc890');
+  assert_equals(await getFileSize(handle), 10);
+}, 'write() called with a string and a valid offset');
+
+directory_test(async (t, root) => {
+const handle = await createEmptyFile(t, 'blob_with_offset', root);
+const stream = await handle.createWritable();
+
+await stream.write('1234567890');
+await stream.write({type: 'write', position: 4, data: new Blob(['abc'])});
+await stream.close();
+
+assert_equals(await getFileContents(handle), '1234abc890');
+assert_equals(await getFileSize(handle), 10);
+}, 'write() called with a blob and a valid offset');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'bad_offset', root);
+  const stream = await handle.createWritable();
+
+  await stream.write({type: 'write', position: 4, data: new Blob(['abc'])});
+  await stream.close();
+
+  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);
+  const stream = await handle.createWritable();
+
+  await stream.write('');
+  await stream.close();
+  assert_equals(await getFileContents(handle), '');
+  assert_equals(await getFileSize(handle), 0);
+}, 'write() with an empty string to an empty file');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'valid_utf8_string', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('foo🤘');
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo🤘');
+  assert_equals(await getFileSize(handle), 7);
+}, 'write() with a valid utf-8 string');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'string_with_unix_line_ending', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('foo\n');
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo\n');
+  assert_equals(await getFileSize(handle), 4);
+}, 'write() with a string with unix line ending preserved');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createEmptyFile(t, 'string_with_windows_line_ending', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('foo\r\n');
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo\r\n');
+  assert_equals(await getFileSize(handle), 5);
+}, 'write() with a string with windows line ending preserved');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'empty_array_buffer', root);
+  const stream = await handle.createWritable();
+
+  const buf = new ArrayBuffer(0);
+  await stream.write(buf);
+  await stream.close();
+  assert_equals(await getFileContents(handle), '');
+  assert_equals(await getFileSize(handle), 0);
+}, 'write() with an empty array buffer to an empty file');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createEmptyFile(t, 'valid_string_typed_byte_array', root);
+  const stream = await handle.createWritable();
+
+  const buf = new ArrayBuffer(3);
+  const intView = new Uint8Array(buf);
+  intView[0] = 0x66;
+  intView[1] = 0x6f;
+  intView[2] = 0x6f;
+  await stream.write(buf);
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+}, 'write() with a valid typed array buffer');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'parent_dir', root);
+  const file_name = 'close_fails_when_dir_removed.txt';
+  const handle = await createEmptyFile(t, file_name, dir);
+  const stream = await handle.createWritable();
+  await stream.write('foo');
+
+  await root.removeEntry('parent_dir', {recursive: true});
+  await promise_rejects_dom(t, 'NotFoundError', stream.close());
+}, 'atomic writes: close() fails when parent directory is removed');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'atomic_writes.txt', root);
+  const stream = await handle.createWritable();
+  await stream.write('foox');
+
+  const stream2 = await handle.createWritable();
+  await stream2.write('bar');
+
+  assert_equals(await getFileSize(handle), 0);
+
+  await stream2.close();
+  assert_equals(await getFileContents(handle), 'bar');
+  assert_equals(await getFileSize(handle), 3);
+
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foox');
+  assert_equals(await getFileSize(handle), 4);
+}, 'atomic writes: writable file streams make atomic changes on close');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'atomic_write_after_close.txt', root);
+  const stream = await handle.createWritable();
+  await stream.write('foo');
+
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+
+  await promise_rejects_js(
+      t, TypeError, stream.write('abc'));
+}, 'atomic writes: write() after close() fails');
+
+directory_test(async (t, root) => {
+  const handle =
+      await createEmptyFile(t, 'atomic_truncate_after_close.txt', root);
+  const stream = await handle.createWritable();
+  await stream.write('foo');
+
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+
+  await promise_rejects_js(t, TypeError, stream.truncate(0));
+}, 'atomic writes: truncate() after close() fails');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'atomic_close_after_close.txt', root);
+  const stream = await handle.createWritable();
+  await stream.write('foo');
+
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'foo');
+  assert_equals(await getFileSize(handle), 3);
+
+  await promise_rejects_js(t, TypeError, stream.close());
+}, 'atomic writes: close() after close() fails');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'there_can_be_only_one.txt', root);
+  const stream = await handle.createWritable();
+  await stream.write('foo');
+
+  // This test might be flaky if there is a race condition allowing
+  // close() to be called multiple times.
+  const success_promises =
+      [...Array(100)].map(() => stream.close().then(() => 1).catch(() => 0));
+  const close_attempts = await Promise.all(success_promises);
+  const success_count = close_attempts.reduce((x, y) => x + y);
+  assert_equals(success_count, 1);
+}, 'atomic writes: only one close() operation may succeed');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'parent_dir', root);
+  const file_name = 'atomic_writable_file_stream_persists_removed.txt';
+  const handle = await createFileWithContents(t, file_name, 'foo', dir);
+
+  const stream = await handle.createWritable();
+  await stream.write('bar');
+
+  await dir.removeEntry(file_name);
+  await promise_rejects_dom(t, 'NotFoundError', getFileContents(handle));
+
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'bar');
+  assert_equals(await getFileSize(handle), 3);
+}, 'atomic writes: writable file stream persists file on close, even if file is removed');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'writer_written', root);
+  const stream = await handle.createWritable();
+  assert_false(stream.locked);
+  const writer = stream.getWriter();
+  assert_true(stream.locked);
+
+  await writer.write('foo');
+  await writer.write(new Blob(['bar']));
+  await writer.write({type: 'seek', position: 0});
+  await writer.write({type: 'write', data: 'baz'});
+  await writer.close();
+
+  assert_equals(await getFileContents(handle), 'bazbar');
+  assert_equals(await getFileSize(handle), 6);
+}, 'getWriter() can be used');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'content.txt', 'very long string', root);
+  const stream = await handle.createWritable();
+
+  await promise_rejects_dom(
+      t, "SyntaxError", stream.write({type: 'truncate'}), 'truncate without size');
+
+}, 'WriteParams: truncate missing size param');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'content.txt', root);
+  const stream = await handle.createWritable();
+
+  await promise_rejects_dom(
+      t, "SyntaxError", stream.write({type: 'write'}), 'write without data');
+
+}, 'WriteParams: write missing data param');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'content.txt', 'seekable', root);
+  const stream = await handle.createWritable();
+
+  await promise_rejects_dom(
+      t, "SyntaxError", stream.write({type: 'seek'}), 'seek without position');
+
+}, 'WriteParams: seek missing position param');
+
+directory_test(async (t, root) => {
+  const source_file =
+      await createFileWithContents(t, 'source_file', 'source data', root);
+  const source_blob = await source_file.getFile();
+  await root.removeEntry(source_file.name);
+
+  const handle = await createEmptyFile(t, 'invalid_blob_test', root);
+  const stream = await handle.createWritable();
+  await promise_rejects_dom(t, "NotFoundError", stream.write(source_blob));
+  await promise_rejects_js(t, TypeError, stream.close());
+
+  assert_equals(await getFileContents(handle), '');
+  assert_equals(await getFileSize(handle), 0);
+}, 'write() with an invalid blob to an empty file should reject');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsFileSystemWritableFileStreamjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js                                (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js   2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,123 @@
</span><ins>+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'trunc_shrink', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('1234567890');
+  await stream.truncate(5);
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '12345');
+  assert_equals(await getFileSize(handle), 5);
+}, 'truncate() to shrink a file');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'trunc_grow', root);
+  const stream = await handle.createWritable();
+
+  await stream.write('abc');
+  await stream.truncate(5);
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), 'abc\0\0');
+  assert_equals(await getFileSize(handle), 5);
+}, 'truncate() to grow a file');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'parent_dir', root);
+  const file_name = 'create_writable_fails_when_dir_removed.txt';
+  const handle = await createEmptyFile(t, file_name, dir);
+
+  await root.removeEntry('parent_dir', {recursive: true});
+  await promise_rejects_dom(t, 'NotFoundError', handle.createWritable());
+}, 'createWritable() fails when parent directory is removed');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'parent_dir', root);
+  const file_name = 'write_fails_when_dir_removed.txt';
+  const handle = await createEmptyFile(t, file_name, dir);
+  const stream = await handle.createWritable();
+
+  await root.removeEntry('parent_dir', {recursive: true});
+  await promise_rejects_dom(t, 'NotFoundError', stream.write('foo'));
+}, 'write() fails when parent directory is removed');
+
+directory_test(async (t, root) => {
+  const dir = await createDirectory(t, 'parent_dir', root);
+  const file_name = 'truncate_fails_when_dir_removed.txt';
+  const handle = await createEmptyFile(t, file_name, dir);
+  const stream = await handle.createWritable();
+
+  await root.removeEntry('parent_dir', {recursive: true});
+  await promise_rejects_dom(t, 'NotFoundError', stream.truncate(0));
+}, 'truncate() fails when parent directory is removed');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'atomic_file_is_copied.txt', 'fooks', root);
+  const stream = await handle.createWritable({keepExistingData: true});
+
+  await stream.write('bar');
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'barks');
+  assert_equals(await getFileSize(handle), 5);
+}, 'createWritable({keepExistingData: true}): atomic writable file stream initialized with source contents');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'atomic_file_is_not_copied.txt', 'very long string', root);
+  const stream = await handle.createWritable({keepExistingData: false});
+
+  await stream.write('bar');
+  assert_equals(await getFileContents(handle), 'very long string');
+  await stream.close();
+  assert_equals(await getFileContents(handle), 'bar');
+  assert_equals(await getFileSize(handle), 3);
+}, 'createWritable({keepExistingData: false}): atomic writable file stream initialized with empty file');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'trunc_smaller_offset.txt', '1234567890', root);
+  const stream = await handle.createWritable({keepExistingData: true});
+
+  await stream.truncate(5);
+  await stream.write('abc');
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), 'abc45');
+  assert_equals(await getFileSize(handle), 5);
+}, 'cursor position: truncate size > offset');
+
+directory_test(async (t, root) => {
+  const handle = await createFileWithContents(
+      t, 'trunc_bigger_offset.txt', '1234567890', root);
+  const stream = await handle.createWritable({keepExistingData: true});
+
+  await stream.seek(6);
+  await stream.truncate(5);
+  await stream.write('abc');
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), '12345abc');
+  assert_equals(await getFileSize(handle), 8);
+}, 'cursor position: truncate size < offset');
+
+directory_test(async (t, root) => {
+  const handle = await createEmptyFile(t, 'contents', root);
+  const stream = await handle.createWritable();
+  assert_false(stream.locked);
+
+  stream.write('abc');
+  assert_false(stream.locked);
+  stream.write('def');
+  assert_false(stream.locked);
+  stream.truncate(9);
+  assert_false(stream.locked);
+  stream.seek(0);
+  assert_false(stream.locked);
+  stream.write('xyz');
+  assert_false(stream.locked);
+  await stream.close();
+
+  assert_equals(await getFileContents(handle), 'xyzdef\0\0\0');
+  assert_equals(await getFileSize(handle), 9);
+}, 'commands are queued, stream is unlocked after each operation');
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessscripttestsw3cimportlog"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/w3c-import.log (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/w3c-import.log                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/w3c-import.log    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,38 @@
</span><ins>+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+       https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-IndexedDB.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-isSameEntry.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-BroadcastChannel.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-Error.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-frames.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-windows.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-MessagePort-workers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-frames.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-windows.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-postMessage-workers.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getDirectoryHandle.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-getFileHandle.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-iteration.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemDirectoryHandle-resolve.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-create-sync-access-handle-dedicated-worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemFileHandle-getFile.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemSyncAccessHandle-flush.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-piped.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream-write.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/script-tests/FileSystemWritableFileStream.js
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window-expected.txt    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,135 @@
</span><ins>+
+FAIL showOpenFilePicker: Showing a picker requires user activation. promise_test: Unhandled rejection with value: object "TypeError: self.showOpenFilePicker is not a function. (In 'self.showOpenFilePicker()', 'self.showOpenFilePicker' is undefined)"
+FAIL showSaveFilePicker: Showing a picker requires user activation. promise_test: Unhandled rejection with value: object "TypeError: self.showSaveFilePicker is not a function. (In 'self.showSaveFilePicker()', 'self.showSaveFilePicker' is undefined)"
+FAIL showDirectoryPicker: Showing a picker requires user activation. promise_test: Unhandled rejection with value: object "TypeError: self.showDirectoryPicker is not a function. (In 'self.showDirectoryPicker()', 'self.showDirectoryPicker' is undefined)"
+FAIL showOpenFilePicker: File picker requires at least one accepted type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({excludeAcceptAllOption: true, types: []})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't be an empty string. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type must have subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'image': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have empty type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'  /plain': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have empty subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'image/  ': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have parameters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+            {types: [{accept: {'text/plain;charset=utf8': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have invalid characters in type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+                               types: [{accept: {'text>foo/plain': ['.txt']}}]
+                             })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have whitespace in the middle. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'text / plain': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: MIME type can't have invalid characters in subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+                {types: [{accept: {'text/plain>foo': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: unknown well-known starting directory. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      startIn: 'secrets',
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: starting directory can         be null. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+                               startIn: null,
+                             })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: starting directory ID contains invalid characters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      id: "inv*l:d\\ chara<ters",
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: starting directory ID cannot exceed 32 characters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      id: "id-length-cannot-exceed-32-characters",
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".extensiontoolong". extension length more than 16.. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt.". extenstion ends with ".". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension "txt". extenstion does not start with ".". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".$txt". illegal character "$". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".t<xt". illegal character "<". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".t/xt". illegal character "". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".     xt". illegal character "/". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt\". illegal characters "\". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt?". illegal character "?". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt*". illegal character "*". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".{txt". illegal character "{". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".}txt". illegal character "}". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension " .txt". illegal whitespace at front of extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ". txt". illegal whitespace in extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt ". illegal whitespace at end of extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".‮txt‮". illegal RTL character. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".tæxt". non-ASCII character "æ". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".קום". non-ASCII character "קום". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".txt🙂". non-ASCII character "🙂". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showOpenFilePicker: invalid extension ".{txt}". illegal characters "{" and "}". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: File picker requires at least one accepted type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({excludeAcceptAllOption: true, types: []})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't be an empty string. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type must have subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'image': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have empty type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'  /plain': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have empty subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'image/  ': ['.foo']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have parameters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+            {types: [{accept: {'text/plain;charset=utf8': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have invalid characters in type. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+                               types: [{accept: {'text>foo/plain': ['.txt']}}]
+                             })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have whitespace in the middle. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({types: [{accept: {'text / plain': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: MIME type can't have invalid characters in subtype. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+                {types: [{accept: {'text/plain>foo': ['.txt']}}]})', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: unknown well-known starting directory. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      startIn: 'secrets',
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: starting directory can         be null. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+                               startIn: null,
+                             })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: starting directory ID contains invalid characters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      id: "inv*l:d\\ chara<ters",
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: starting directory ID cannot exceed 32 characters. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod]({
+      id: "id-length-cannot-exceed-32-characters",
+    })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".extensiontoolong". extension length more than 16.. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt.". extenstion ends with ".". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension "txt". extenstion does not start with ".". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".$txt". illegal character "$". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".t<xt". illegal character "<". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".t/xt". illegal character "". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".     xt". illegal character "/". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt\". illegal characters "\". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt?". illegal character "?". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt*". illegal character "*". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".{txt". illegal character "{". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".}txt". illegal character "}". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension " .txt". illegal whitespace at front of extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ". txt". illegal whitespace in extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt ". illegal whitespace at end of extension. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".‮txt‮". illegal RTL character. promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".tæxt". non-ASCII character "æ". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".קום". non-ASCII character "קום". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".txt🙂". non-ASCII character "🙂". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+FAIL showSaveFilePicker: invalid extension ".{txt}". illegal characters "{" and "}". promise_test: Unhandled rejection with value: object "TypeError: self[showPickerMethod] is not a function. (In 'self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] })', 'self[showPickerMethod]' is undefined)"
+
</ins></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.html (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.html                         (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.html    2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<!-- This file is required for WebKit test infrastructure to run the templated test -->
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessshowPickererrorshttpswindowjs"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.js (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.js                           (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.js      2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,142 @@
</span><ins>+// META: script=resources/test-helpers.js
+
+promise_test(async t => {
+  await promise_rejects_dom(t, 'SecurityError', self.showOpenFilePicker());
+}, 'showOpenFilePicker: Showing a picker requires user activation.');
+
+promise_test(async t => {
+  await promise_rejects_dom(t, 'SecurityError', self.showSaveFilePicker());
+}, 'showSaveFilePicker: Showing a picker requires user activation.');
+
+promise_test(async t => {
+  await promise_rejects_dom(t, 'SecurityError', self.showDirectoryPicker());
+}, 'showDirectoryPicker: Showing a picker requires user activation.');
+
+// TODO(mek): Add tests for cross-origin iframes, opaque origins, etc.
+
+define_file_picker_error_tests('showOpenFilePicker');
+define_file_picker_error_tests('showSaveFilePicker');
+
+function define_file_picker_error_tests(showPickerMethod) {
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({excludeAcceptAllOption: true, types: []}));
+  }, showPickerMethod + ': File picker requires at least one accepted type.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'': ['.foo']}}]}));
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'  ': ['.foo']}}]}));
+  }, showPickerMethod + ': MIME type can\'t be an empty string.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'image': ['.foo']}}]}));
+  }, showPickerMethod + ': MIME type must have subtype.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'  /plain': ['.foo']}}]}));
+  }, showPickerMethod + ': MIME type can\'t have empty type.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'image/  ': ['.foo']}}]}));
+  }, showPickerMethod + ': MIME type can\'t have empty subtype.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod](
+            {types: [{accept: {'text/plain;charset=utf8': ['.txt']}}]}));
+  }, showPickerMethod + ': MIME type can\'t have parameters.');
+
+  promise_test(async t => {
+    await promise_rejects_js(t, TypeError, self[showPickerMethod]({
+                               types: [{accept: {'text>foo/plain': ['.txt']}}]
+                             }));
+  }, showPickerMethod + ': MIME type can\'t have invalid characters in type.');
+
+  promise_test(async t => {
+    await promise_rejects_js(
+        t, TypeError,
+        self[showPickerMethod]({types: [{accept: {'text / plain': ['.txt']}}]}));
+  }, showPickerMethod + ': MIME type can\'t have whitespace in the middle.');
+
+  promise_test(
+      async t => {
+        await promise_rejects_js(
+            t, TypeError,
+            self[showPickerMethod](
+                {types: [{accept: {'text/plain>foo': ['.txt']}}]}));
+      },
+      showPickerMethod +
+          ': MIME type can\'t have invalid characters in subtype.');
+
+  promise_test(async t => {
+    await promise_rejects_js(t, TypeError, self[showPickerMethod]({
+      startIn: 'secrets',
+    }));
+  }, showPickerMethod + ': unknown well-known starting directory.');
+
+  promise_test(async t => {
+    await promise_rejects_js(t, TypeError, self[showPickerMethod]({
+                               startIn: null,
+                             }));
+  }, showPickerMethod + ': starting directory can\t be null.');
+
+  promise_test(async t => {
+    await promise_rejects_js(t, TypeError, self[showPickerMethod]({
+      id: "inv*l:d\\ chara<ters",
+    }));
+  }, showPickerMethod + ': starting directory ID contains invalid characters.');
+
+  promise_test(async t => {
+    await promise_rejects_js(t, TypeError, self[showPickerMethod]({
+      id: "id-length-cannot-exceed-32-characters",
+    }));
+  }, showPickerMethod + ': starting directory ID cannot exceed 32 characters.');
+
+  const invalid_extensions = {
+    '.extensiontoolong': 'extension length more than 16.',
+    '.txt.': 'extenstion ends with "."',
+    'txt': 'extenstion does not start with "."',
+    '.$txt' : 'illegal character "$"',
+    '.t<xt': 'illegal character "<"',
+    '.t/xt': 'illegal character "\"',
+    '.\txt': 'illegal character "/"',
+    '.txt\\': 'illegal characters "\\"',
+    '.txt?': 'illegal character "?"',
+    '.txt*': 'illegal character "*"',
+    '.{txt': 'illegal character "{"',
+    '.}txt': 'illegal character "}"',
+    ' .txt': 'illegal whitespace at front of extension',
+    '. txt': 'illegal whitespace in extension',
+    '.txt ': 'illegal whitespace at end of extension',
+    '.\u202etxt\u202e' : 'illegal RTL character',
+    '.t\u00E6xt': 'non-ASCII character "æ"',
+    '.קום': 'non-ASCII character "קום"',
+    '.txt🙂': 'non-ASCII character "🙂"',
+    '.{txt}': 'illegal characters "{" and "}"',
+  }
+
+  for (const [extension, description] of Object.entries(invalid_extensions)) {
+    define_file_picker_extension_error_test(showPickerMethod, extension, description)
+  }
+}
+
+function define_file_picker_extension_error_test(showPickerMethod, extension, description) {
+  promise_test(async t => {
+    await promise_rejects_js(
+      t, TypeError,
+      self[showPickerMethod](
+        { types: [{ accept: { 'text/plain': ['.txt', extension] } }] }));
+  }, showPickerMethod + ': invalid extension "' + extension + '". ' + description + ".");
+}
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfilesystemaccessw3cimportlog"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/w3c-import.log (0 => 281769)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/w3c-import.log                              (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/file-system-access/w3c-import.log 2021-08-30 18:22:32 UTC (rev 281769)
</span><span class="lines">@@ -0,0 +1,48 @@
</span><ins>+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+       https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/META.yml
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/README.md
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/idlharness.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/opaque-origin.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-IndexedDB.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-isSameEntry.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-BroadcastChannel.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-Error.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-frames.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-windows.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-MessagePort-workers.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-frames.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-windows.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-postMessage-workers.https.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemBaseHandle-remove.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-iteration.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-resolve.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle-dedicated-worker.https.tentative.window.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-getFile.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemFileHandle-sync-access-handle-lock.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-close.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-flush.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-getSize.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-read-write.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemSyncAccessHandle-truncate.https.tentative.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-piped.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream-write.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/sandboxed_FileSystemWritableFileStream.https.any.js
+/LayoutTests/imported/w3c/web-platform-tests/file-system-access/showPicker-errors.https.window.js
</ins></span></pre>
</div>
</div>

</body>
</html>