Refresh wpt tests up to d686014
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Aug 2016 10:41:11 +0000 (10:41 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Aug 2016 10:41:11 +0000 (10:41 +0000)
https://bugs.webkit.org/show_bug.cgi?id=160446

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-03
Reviewed by Alex Christensen.

* resources/ImportExpectations:
* resources/TestRepositories:
* resources/web-platform-tests-modules.json:
* web-platform-tests/XMLHttpRequest/FormData-append.html:
* web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js: Added.
(test):
(string_appeared_here.test):
(string_appeared_here.async_test):
* web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html: Removed.
* web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js: Removed.
* web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js: Removed.
* web-platform-tests/XMLHttpRequest/headers-normalize-response-expected.txt: Added.
* web-platform-tests/XMLHttpRequest/headers-normalize-response.htm: Added.
* web-platform-tests/XMLHttpRequest/open-url-multi-window.htm:
* web-platform-tests/XMLHttpRequest/resources/last-modified.py:
(main):
* web-platform-tests/XMLHttpRequest/resources/parse-headers.py: Added.
(main):
* web-platform-tests/XMLHttpRequest/resources/w3c-import.log:
* web-platform-tests/XMLHttpRequest/responsexml-document-properties-expected.txt:
* web-platform-tests/XMLHttpRequest/responsexml-document-properties.htm:
* web-platform-tests/XMLHttpRequest/send-entity-body-document-expected.txt:
* web-platform-tests/XMLHttpRequest/send-entity-body-empty-expected.txt:
* web-platform-tests/XMLHttpRequest/send-entity-body-empty.htm:
* web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async-expected.txt:
* web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async.htm:
* web-platform-tests/XMLHttpRequest/send-entity-body-get-head-expected.txt:
* web-platform-tests/XMLHttpRequest/send-entity-body-get-head.htm:
* web-platform-tests/XMLHttpRequest/send-entity-body-none-expected.txt:
* web-platform-tests/XMLHttpRequest/send-entity-body-none.htm:
* web-platform-tests/XMLHttpRequest/setrequestheader-content-type-expected.txt:
* web-platform-tests/XMLHttpRequest/setrequestheader-content-type.htm:
* web-platform-tests/XMLHttpRequest/w3c-import.log:
* web-platform-tests/dom/events/AddEventListenerOptions-once-expected.txt: Added.
* web-platform-tests/dom/events/AddEventListenerOptions-once.html: Added.
* web-platform-tests/dom/events/w3c-import.log:
* web-platform-tests/dom/lists/DOMTokenList-iteration-expected.txt: Added.
* web-platform-tests/dom/lists/DOMTokenList-iteration.html: Added.
* web-platform-tests/dom/lists/w3c-import.log:
* web-platform-tests/dom/nodes/Node-childNodes-expected.txt:
* web-platform-tests/dom/nodes/Node-childNodes.html:
* web-platform-tests/domparsing/insert_adjacent_html-expected.txt:
* web-platform-tests/fetch/api/basic/request-headers-expected.txt:
* web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt:
* web-platform-tests/fetch/api/basic/request-headers.js:
* web-platform-tests/fetch/api/basic/request-referrer-expected.txt: Added.
* web-platform-tests/fetch/api/basic/request-referrer.html: Added.
* web-platform-tests/fetch/api/basic/request-referrer.js: Added.
(testReferrer):
* web-platform-tests/fetch/api/basic/w3c-import.log:
* web-platform-tests/fetch/api/cors/cors-cookies-worker-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-no-referrer-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-no-referrer-worker-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-no-referrer.html.headers:
* web-platform-tests/fetch/api/policies/referrer-no-referrer.js.headers:
* web-platform-tests/fetch/api/policies/referrer-origin-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-expected.txt: Copied from LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-expected.txt.
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker-expected.txt: Copied from LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-expected.txt.
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html: Added.
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html: Added.
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers: Added.
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js: Added.
(promise_test):
* web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers: Added.
* web-platform-tests/fetch/api/policies/referrer-origin-worker-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-origin.html.headers:
* web-platform-tests/fetch/api/policies/referrer-origin.js.headers:
* web-platform-tests/fetch/api/policies/referrer-unsafe-url-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-unsafe-url-worker-expected.txt:
* web-platform-tests/fetch/api/policies/referrer-unsafe-url.html.headers:
* web-platform-tests/fetch/api/policies/referrer-unsafe-url.js.headers:
* web-platform-tests/fetch/api/policies/w3c-import.log:
* web-platform-tests/fetch/api/request/request-cache-expected.txt:
* web-platform-tests/fetch/api/request/resources/get-host-info.sub.js: Removed.
* web-platform-tests/fetch/nosniff/resources/image.py:
(main):
* web-platform-tests/fetch/nosniff/stylesheet-expected.txt:
* web-platform-tests/fetch/nosniff/stylesheet.html:
* web-platform-tests/html/dom/interfaces-expected.txt:
* web-platform-tests/html/dom/interfaces.html:
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen-expected.txt:
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen.html:
* web-platform-tests/html/semantics/embedded-content/the-img-element/environment-changes/viewport-change-expected.txt:
* web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li-expected.txt:
* web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li.html:
* web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open-expected.txt: Added.
* web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html: Added.
* web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log:
* web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03-expected.txt: Added.
* web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html: Added.
* web-platform-tests/html/semantics/scripting-1/the-script-element/w3c-import.log:
* web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods-expected.txt:
* web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods.html:
* web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row-expected.txt: Added.
* web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html: Added.
* web-platform-tests/html/semantics/tabular-data/the-table-element/w3c-import.log:
* web-platform-tests/lint.whitelist:
* web-platform-tests/service-workers/tools/blink-import.py:
(main):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@204079 268f45cc-cd09-0410-ab3c-d52691b4dbfc

89 files changed:
LayoutTests/imported/w3c/ChangeLog
LayoutTests/imported/w3c/resources/ImportExpectations
LayoutTests/imported/w3c/resources/TestRepositories
LayoutTests/imported/w3c/resources/web-platform-tests-modules.json
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/FormData-append.html
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html [deleted file]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js [deleted file]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js [deleted file]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response.htm [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/open-url-multi-window.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/last-modified.py
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/parse-headers.py [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/responsexml-document-properties-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/responsexml-document-properties.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-document-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-empty-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-empty.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-get-head-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-get-head.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-none-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/send-entity-body-none.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/setrequestheader-content-type-expected.txt
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/setrequestheader-content-type.htm
LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/dom/events/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/dom/nodes/Node-childNodes-expected.txt
LayoutTests/imported/w3c/web-platform-tests/dom/nodes/Node-childNodes.html
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers.js
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.js [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer-worker-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer.html.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer.js.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-worker-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin.html.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin.js.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-unsafe-url-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-unsafe-url-worker-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-unsafe-url.html.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-unsafe-url.js.headers
LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/request-cache-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/resources/get-host-info.sub.js [deleted file]
LayoutTests/imported/w3c/web-platform-tests/fetch/nosniff/resources/image.py
LayoutTests/imported/w3c/web-platform-tests/fetch/nosniff/stylesheet-expected.txt
LayoutTests/imported/w3c/web-platform-tests/fetch/nosniff/stylesheet.html
LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt
LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces.html
LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen-expected.txt
LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen.html
LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-img-element/environment-changes/viewport-change-expected.txt
LayoutTests/imported/w3c/web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li-expected.txt
LayoutTests/imported/w3c/web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li.html
LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods-expected.txt
LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods.html
LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row-expected.txt [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html [new file with mode: 0644]
LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/w3c-import.log
LayoutTests/imported/w3c/web-platform-tests/lint.whitelist
LayoutTests/imported/w3c/web-platform-tests/service-workers/tools/blink-import.py

index be7c568a3878fe4b0bc9b578d54db087b0065fc1..6066f30b523d07adef8b621224e4265366490287 100644 (file)
@@ -1,3 +1,110 @@
+2016-08-03  Youenn Fablet  <youenn@apple.com>
+
+        Refresh wpt tests up to d686014
+        https://bugs.webkit.org/show_bug.cgi?id=160446
+
+        Reviewed by Alex Christensen.
+
+        * resources/ImportExpectations:
+        * resources/TestRepositories:
+        * resources/web-platform-tests-modules.json:
+        * web-platform-tests/XMLHttpRequest/FormData-append.html:
+        * web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js: Added.
+        (test):
+        (string_appeared_here.test):
+        (string_appeared_here.async_test):
+        * web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html: Removed.
+        * web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js: Removed.
+        * web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js: Removed.
+        * web-platform-tests/XMLHttpRequest/headers-normalize-response-expected.txt: Added.
+        * web-platform-tests/XMLHttpRequest/headers-normalize-response.htm: Added.
+        * web-platform-tests/XMLHttpRequest/open-url-multi-window.htm:
+        * web-platform-tests/XMLHttpRequest/resources/last-modified.py:
+        (main):
+        * web-platform-tests/XMLHttpRequest/resources/parse-headers.py: Added.
+        (main):
+        * web-platform-tests/XMLHttpRequest/resources/w3c-import.log:
+        * web-platform-tests/XMLHttpRequest/responsexml-document-properties-expected.txt:
+        * web-platform-tests/XMLHttpRequest/responsexml-document-properties.htm:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-document-expected.txt:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-empty-expected.txt:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-empty.htm:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async-expected.txt:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-get-head-async.htm:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-get-head-expected.txt:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-get-head.htm:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-none-expected.txt:
+        * web-platform-tests/XMLHttpRequest/send-entity-body-none.htm:
+        * web-platform-tests/XMLHttpRequest/setrequestheader-content-type-expected.txt:
+        * web-platform-tests/XMLHttpRequest/setrequestheader-content-type.htm:
+        * web-platform-tests/XMLHttpRequest/w3c-import.log:
+        * web-platform-tests/dom/events/AddEventListenerOptions-once-expected.txt: Added.
+        * web-platform-tests/dom/events/AddEventListenerOptions-once.html: Added.
+        * web-platform-tests/dom/events/w3c-import.log:
+        * web-platform-tests/dom/lists/DOMTokenList-iteration-expected.txt: Added.
+        * web-platform-tests/dom/lists/DOMTokenList-iteration.html: Added.
+        * web-platform-tests/dom/lists/w3c-import.log:
+        * web-platform-tests/dom/nodes/Node-childNodes-expected.txt:
+        * web-platform-tests/dom/nodes/Node-childNodes.html:
+        * web-platform-tests/domparsing/insert_adjacent_html-expected.txt:
+        * web-platform-tests/fetch/api/basic/request-headers-expected.txt:
+        * web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt:
+        * web-platform-tests/fetch/api/basic/request-headers.js:
+        * web-platform-tests/fetch/api/basic/request-referrer-expected.txt: Added.
+        * web-platform-tests/fetch/api/basic/request-referrer.html: Added.
+        * web-platform-tests/fetch/api/basic/request-referrer.js: Added.
+        (testReferrer):
+        * web-platform-tests/fetch/api/basic/w3c-import.log:
+        * web-platform-tests/fetch/api/cors/cors-cookies-worker-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-no-referrer-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-no-referrer-worker-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-no-referrer.html.headers:
+        * web-platform-tests/fetch/api/policies/referrer-no-referrer.js.headers:
+        * web-platform-tests/fetch/api/policies/referrer-origin-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-expected.txt: Copied from LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-expected.txt.
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker-expected.txt: Copied from LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-expected.txt.
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html: Added.
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html: Added.
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers: Added.
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js: Added.
+        (promise_test):
+        * web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers: Added.
+        * web-platform-tests/fetch/api/policies/referrer-origin-worker-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-origin.html.headers:
+        * web-platform-tests/fetch/api/policies/referrer-origin.js.headers:
+        * web-platform-tests/fetch/api/policies/referrer-unsafe-url-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-unsafe-url-worker-expected.txt:
+        * web-platform-tests/fetch/api/policies/referrer-unsafe-url.html.headers:
+        * web-platform-tests/fetch/api/policies/referrer-unsafe-url.js.headers:
+        * web-platform-tests/fetch/api/policies/w3c-import.log:
+        * web-platform-tests/fetch/api/request/request-cache-expected.txt:
+        * web-platform-tests/fetch/api/request/resources/get-host-info.sub.js: Removed.
+        * web-platform-tests/fetch/nosniff/resources/image.py:
+        (main):
+        * web-platform-tests/fetch/nosniff/stylesheet-expected.txt:
+        * web-platform-tests/fetch/nosniff/stylesheet.html:
+        * web-platform-tests/html/dom/interfaces-expected.txt:
+        * web-platform-tests/html/dom/interfaces.html:
+        * web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen-expected.txt:
+        * web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-allowfullscreen.html:
+        * web-platform-tests/html/semantics/embedded-content/the-img-element/environment-changes/viewport-change-expected.txt:
+        * web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li-expected.txt:
+        * web-platform-tests/html/semantics/grouping-content/the-li-element/grouping-li.html:
+        * web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open-expected.txt: Added.
+        * web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html: Added.
+        * web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log:
+        * web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03-expected.txt: Added.
+        * web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html: Added.
+        * web-platform-tests/html/semantics/scripting-1/the-script-element/w3c-import.log:
+        * web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods-expected.txt:
+        * web-platform-tests/html/semantics/tabular-data/the-table-element/caption-methods.html:
+        * web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row-expected.txt: Added.
+        * web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html: Added.
+        * web-platform-tests/html/semantics/tabular-data/the-table-element/w3c-import.log:
+        * web-platform-tests/lint.whitelist:
+        * web-platform-tests/service-workers/tools/blink-import.py:
+        (main):
+
 2016-08-02  Chris Dumez  <cdumez@apple.com>
 
         Drop custom bindings code for HTMLOptionsCollection.remove()
index 4f9b946afa5f00e5c5a327e6070e3e366ca4792b..1dfeed8fa1aea5f68123baa0b532720cb613798d 100644 (file)
@@ -124,6 +124,7 @@ web-platform-tests/dom/nodes/Node-nodeName.xhtml [ Skip ]
 web-platform-tests/dom/nodes/ParentNode-querySelector-All.xht [ Skip ]
 web-platform-tests/dom/traversal/unfinished [ Skip ]
 #web-platform-tests/domparsing [ Import ]
+web-platform-tests/domparsing/insert_adjacent_html.xhtml [ Skip ]
 web-platform-tests/generic-sensor [ Skip ]
 web-platform-tests/domparsing/DOMParser-parseFromString-xml.html [ Skip ]
 web-platform-tests/domparsing/XMLSerializer-serializeToString.html [ Skip ]
@@ -206,6 +207,7 @@ web-platform-tests/notifications [ Skip ]
 web-platform-tests/old-tests [ Skip ]
 web-platform-tests/orientation-event [ Skip ]
 web-platform-tests/page-visibility [ Skip ]
+web-platform-tests/payment-request [ Skip ]
 web-platform-tests/performance-timeline [ Skip ]
 web-platform-tests/pointerevents [ Skip ]
 web-platform-tests/pointerlock [ Skip ]
index 12dc839c4956751da405a249081647df48d4cac0..9ccf9fd2bab6225b76b5b2c3371c361b6f753ce1 100644 (file)
@@ -15,7 +15,7 @@
     {
         "name": "web-platform-tests",
         "url": "https://github.com/w3c/web-platform-tests.git", 
-        "revision": "98ec1ad",
+        "revision": "d686014",
         "paths_to_skip": [
             "conformance-checkers",
             "docs",
index 6365b821ae0fc15336a0c4aa0983b8edd0c3fdd4..fbdf477dade530c4bc175a6dd4f8d4038fd3e680 100644 (file)
@@ -28,8 +28,8 @@
         "path": [
             "tools"
         ], 
-        "url": "https://github.com/w3c/wpt-tools/archive/09258ba099c2cd0f7c107a5d4e8b5f458c209a47.tar.gz", 
-        "url_subpath": "wpt-tools-09258ba099c2cd0f7c107a5d4e8b5f458c209a47"
+        "url": "https://github.com/w3c/wpt-tools/archive/35de4d0ddd1427e07c1b8b68c2d9bace0b2a08da.tar.gz", 
+        "url_subpath": "wpt-tools-35de4d0ddd1427e07c1b8b68c2d9bace0b2a08da"
     }, 
     {
         "path": [
index 0b81acc082502a47f5c2061f47a1d12302499e63..bf6c66d0f665df8cfb30b97063cca33442900250 100644 (file)
         assert_equals(fd.get('key'), "null");
     }, 'testFormDataAppendToFormNull2');
     test(function() {
-        assert_object_equals(create_formdata(['key', new Blob(), 'blank.txt']).get('key'),
-                             new File(new Blob(), 'blank.txt'));
+        var before = new Date(new Date().getTime() - 2000); // two seconds ago, in case there's clock drift
+        var fd = create_formdata(['key', new Blob(), 'blank.txt']).get('key');
+        assert_equals(fd.name, "blank.txt");
+        assert_equals(fd.type, "");
+        assert_equals(fd.size, 0);
+        assert_greater_than_equal(fd.lastModified, before);
+        assert_less_than_equal(fd.lastModified, new Date());
     }, 'testFormDataAppendEmptyBlob');
 
     function create_formdata() {
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js
new file mode 100644 (file)
index 0000000..96e95c9
--- /dev/null
@@ -0,0 +1,40 @@
+test(function() {
+  var client = new XMLHttpRequest()
+  assert_false(client.withCredentials, "withCredentials defaults to false")
+  client.withCredentials = true
+  assert_true(client.withCredentials, "is true after setting")
+}, "default value is false, set value is true")
+
+test(function() {
+  var client = new XMLHttpRequest()
+  client.open("GET", "resources/delay.py?ms=1000", true)
+  client.withCredentials = true
+  assert_true(client.withCredentials, "set in OPEN state")
+}, "can also be set in OPEN state")
+
+test(function() {
+  var client = new XMLHttpRequest()
+  client.open("GET", "resources/delay.py?ms=1000", false)
+  client.withCredentials = true
+  assert_true(client.withCredentials, "set in OPEN state")
+}, "setting on synchronous XHR")
+
+async_test(function() {
+  var client = new XMLHttpRequest()
+  client.open("GET", "resources/delay.py?ms=1000")
+  client.send()
+  assert_throws("InvalidStateError", function() { client.withCredentials = true })
+  client.onreadystatechange = this.step_func(function() {
+    assert_throws("InvalidStateError", function() { client.withCredentials = true })
+    if (client.readyState === 4) {
+      this.done()
+    }
+  })
+}, "setting withCredentials when not in UNSENT, OPENED state (asynchronous)")
+
+test(function() {
+  var client = new XMLHttpRequest()
+  client.open("GET", "resources/delay.py?ms=1000", false)
+  client.send();
+  assert_throws("InvalidStateError", function() { client.withCredentials = true })
+}, "setting withCredentials when in DONE state (synchronous)")
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html
deleted file mode 100644 (file)
index cafbbb6..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-<!doctype html>
-<meta charset=utf-8>
-<title>XMLHttpRequest#withCredentials</title>
-<script src="/resources/testharness.js"></script>
-<script src="/resources/testharnessreport.js"></script>
-<script src=XMLHttpRequest-withCredentials.js></script>
-<link rel="help" href="https://xhr.spec.whatwg.org/#the-withcredentials-attribute"
-      data-tested-assertations="following::ol/li[1] following::ol/li[2]
-                                following::ol/li[3] following::ol/li[4]">
-<div id="log"></div>
-<script>
-test_withCredentials(false)
-</script>
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js
deleted file mode 100644 (file)
index ea945e8..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-function test_withCredentials(worker) {
-  test(function() {
-    var client = new XMLHttpRequest()
-    assert_false(client.withCredentials, "withCredentials defaults to false")
-    client.withCredentials = true
-    assert_true(client.withCredentials, "is true after setting")
-  }, "default value is false, set value is true")
-
-  test(function() {
-    var client = new XMLHttpRequest()
-    client.open("GET", "resources/delay.py?ms=1000", true)
-    client.withCredentials = true
-    assert_true(client.withCredentials, "set in OPEN state")
-  }, "can also be set in OPEN state")
-
-  test(function() {
-    var client = new XMLHttpRequest()
-    client.open("GET", "resources/delay.py?ms=1000", false)
-    client.withCredentials = true
-    assert_true(client.withCredentials, "set in OPEN state")
-  }, "setting on synchronous XHR")
-
-  async_test(function() {
-    var client = new XMLHttpRequest()
-    client.open("GET", "resources/delay.py?ms=1000")
-    client.send()
-    assert_throws("InvalidStateError", function() { client.withCredentials = true })
-    client.onreadystatechange = this.step_func(function() {
-      assert_throws("InvalidStateError", function() { client.withCredentials = true })
-      if (client.readyState === 4) {
-        this.done()
-      }
-    })
-  }, "setting withCredentials when not in UNSENT, OPENED state (asynchronous)")
-
-  test(function() {
-    var client = new XMLHttpRequest()
-    client.open("GET", "resources/delay.py?ms=1000", false)
-    client.send();
-    assert_throws("InvalidStateError", function() { client.withCredentials = true })
-  }, "setting withCredentials when in DONE state (synchronous)")
-}
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js
deleted file mode 100644 (file)
index 6e89fec..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-importScripts("/resources/testharness.js")
-importScripts("XMLHttpRequest-withCredentials.js")
-test_withCredentials(true);
-done()
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response-expected.txt
new file mode 100644 (file)
index 0000000..85cd9df
--- /dev/null
@@ -0,0 +1,19 @@
+Whitespace and null in response header values
+
+
+PASS Header value: hello_world\0 
+PASS Header value: \0hello_world 
+PASS Header value: hello\0world 
+PASS Header value: __hello_world 
+PASS Header value: hello_world__ 
+PASS Header value: __hello_world__ 
+PASS Header value: [tab]hello_world 
+PASS Header value: hello_world[tab] 
+PASS Header value: [tab]hello_world[tab] 
+PASS Header value: hello______world 
+PASS Header value: hello[tab]world 
+PASS Header value: \0 
+PASS Header value: ___ 
+PASS Header value: [tab] 
+PASS Header value:  
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response.htm b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response.htm
new file mode 100644 (file)
index 0000000..466b0d9
--- /dev/null
@@ -0,0 +1,42 @@
+<!DOCTYPE html>
+<meta charset=utf-8>
+<title>Whitespace and null in header values</title>
+<script src=/resources/testharness.js></script>
+<script src=/resources/testharnessreport.js></script>
+<script src=support.js?pipe=sub></script>
+
+<h1>Whitespace and null in response header values</h1>
+
+<div id=log></div>
+
+<script>
+
+function matchHeaderValue(val) {
+    test(function () {
+        var client = new XMLHttpRequest();
+        var trimmed = val.trim();
+        client.open("GET", "resources/parse-headers.py?my-custom-header="+encodeURIComponent(val), false);
+        client.send();
+        var r = client.getResponseHeader("My-Custom-Header");
+
+        assert_equals(r, trimmed);
+    }, "Header value: " + val.replace(/\t/g, "[tab]").replace(/ /g, "_").replace("\0", "\\0"));
+}
+
+matchHeaderValue("hello world\0");
+matchHeaderValue("\0hello world");
+matchHeaderValue("hello\0world");
+matchHeaderValue("  hello world");
+matchHeaderValue("hello world  ");
+matchHeaderValue("  hello world  ");
+matchHeaderValue("\thello world");
+matchHeaderValue("hello world\t");
+matchHeaderValue("\thello world\t");
+matchHeaderValue("hello      world");
+matchHeaderValue("hello\tworld");
+matchHeaderValue("\0");
+matchHeaderValue("   ");
+matchHeaderValue("\t");
+matchHeaderValue("");
+
+</script>
index b84aaa57fedec65207a65fc1d33ec28053e98e3f..347f4b7e59ca555f2da23c3fd5affd89061edd98 100644 (file)
           var client = new self[0].XMLHttpRequest()
           client.onreadystatechange = function() {
             test.step(function() {
-              if(client.readyState == 4)
+              if(client.readyState == 4) {
                 assert_equals(client.responseText, "bottom\n")
                 test.done()
+              }
             })
           }
           client.open("GET", "folder.txt")
index 4f3a14c7341f42b150052495f89a53aaf5bde4b0..ef05a6343c16a53eaad0e0e17daf65acdd7f6487 100644 (file)
@@ -4,4 +4,4 @@ def main(request, response):
     srcmoddt = datetime.datetime.fromtimestamp(os.path.getmtime(srcpath))
     response.headers.set("Last-Modified", srcmoddt.strftime("%a, %d %b %Y %H:%M:%S GMT"))
     response.headers.set("Content-Type", "application/xml")
-    return open(srcpath).read()
+    return open(srcpath, "r").read()
diff --git a/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/parse-headers.py b/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/parse-headers.py
new file mode 100644 (file)
index 0000000..fdc6265
--- /dev/null
@@ -0,0 +1,10 @@
+import json
+
+def main(request, response):
+
+    content = ""
+    if "my-custom-header" in request.GET:
+        val = request.GET.first("my-custom-header")
+        response.headers.set("My-Custom-Header", val)
+
+    return content
index 578d8ae67d3d66f89b45a83f691262f2b32b9475..cb5a11542d10b27f1a25e2b8231cb303bf21ffb8 100644 (file)
@@ -37,6 +37,7 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/inspect-headers.py
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/invalid-utf8-html.py
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/last-modified.py
+/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/parse-headers.py
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/redirect.py
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/requri.py
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/resources/shift-jis-html.py
index bed90478d720baf4ad4d1b238eb8c757aa26f4bd..56317a179a7b6c0015444a0b73ba930cfc6db2f9 100644 (file)
@@ -16,7 +16,7 @@ PASS all
 FAIL links assert_equals: expected (undefined) undefined but got (object) object "[object HTMLCollection]"
 PASS cookie 
 PASS lastModified set to time of response if no HTTP header provided 
-FAIL lastModified set to related HTTP header if provided assert_equals: expected 1468404072000 but got 1468410886000
+FAIL lastModified set to related HTTP header if provided assert_equals: expected 1470132319000 but got 1470133687000
 PASS cookie (after setting it) 
 PASS styleSheets 
 PASS implementation 
index 1c23cf4c29d016a79d8d0001174a1a19865ccff9..c12f21b260b69bd636e33179d392c5f3ef73ce73 100644 (file)
@@ -45,7 +45,7 @@
 
       test(function() {
         var lastModified = Math.floor(new Date(client.responseXML.lastModified).getTime() / 1000);
-        var now = Math.floor(new Date().getTime() / 1000);
+        var now = Math.floor(new Date().getTime(new Date().getTime() + 2000) / 1000); // two seconds from now, in case there's clock drift
         assert_greater_than_equal(lastModified, timePreXHR);
         assert_less_than_equal(lastModified, now);
       }, 'lastModified set to time of response if no HTTP header provided')
index c944b1aca958a46f392f4dcc7bdb96a2fc97bffc..ad563d4fdd2eff85ec6e5bfc4c5d3910f5538eba 100644 (file)
@@ -1,10 +1,10 @@
          
 
-PASS XML document, windows-1252 
 PASS HTML document, invalid UTF-8 
+PASS XML document, windows-1252 
 PASS HTML document, shift-jis 
 PASS plain text file 
+PASS empty div 
 PASS img tag 
 PASS image file 
-PASS empty div 
 
index 65cef9f391f8c7ca4bbee8e18f384d94e7a33686..973724355ba987cf0b9599ab5bad294180146952 100644 (file)
@@ -1,3 +1,5 @@
 
-PASS XMLHttpRequest: send("") - empty entity body 
+PASS XMLHttpRequest: send("") - empty entity body (POST) 
+PASS XMLHttpRequest: send("") - empty entity body (PUT) 
+FAIL XMLHttpRequest: send("") - empty entity body (HEAD) assert_equals: expected "NO" but got "0"
 
index ab074c77287d1899c0eb83c795ea9166187f9748..f307e778091edf13a268e92d9137429c64305a02 100644 (file)
   <body>
     <div id="log"></div>
     <script>
-      test(function() {
+      function request(method) {
         var client = new XMLHttpRequest()
-        client.open("POST", "resources/content.py", false)
+        client.open(method, "resources/content.py", false)
         client.upload.onloadstart = function(){assert_unreached('this event should not fire for empty strings')}
         client.send("")
-        assert_equals(client.getResponseHeader("x-request-content-length"), "0")
-      })
+        var expectedLength = method == "HEAD" ? "NO" : "0";
+        assert_equals(client.getResponseHeader("x-request-content-length"), expectedLength)
+      }
+      test(function() { request("POST"); }, document.title + " (POST)");
+      test(function() { request("PUT"); }, document.title + " (PUT)");
+      test(function() { request("HEAD"); }, document.title + " (HEAD)");
     </script>
   </body>
 </html>
index 5de1ad5c94c17bb03bec4a8c7a26367d17d1f36b..63b783d0155192276c0a28fd3187b38ecf8a7927 100644 (file)
@@ -1,4 +1,4 @@
 
 PASS XMLHttpRequest: send() - non-empty data argument and GET/HEAD - async, no upload events should fire (GET) 
-PASS XMLHttpRequest: send() - non-empty data argument and GET/HEAD - async, no upload events should fire (HEAD) 
+FAIL XMLHttpRequest: send() - non-empty data argument and GET/HEAD - async, no upload events should fire (HEAD) assert_equals: expected "NO" but got "0"
 
index f8a5a59c16b6800a0f75e0eb3c8807c0124b7eae..ff4c4b4cac027658c3bcd9e895271db383ee8dd2 100644 (file)
         client.upload.addEventListener('loadstart', logEvt)
         client.addEventListener('loadend', function(){
           test.step(function(){
-            if (method === "HEAD") {
-              // Fetch 4.4.3 --- Set Content-Length to 0 if method is HEAD and
-              // request's body is null.
-              assert_equals(client.getResponseHeader("x-request-content-length"), "0")
-            } else {
-              assert_equals(client.getResponseHeader("x-request-content-length"), "NO")
-            }
+            assert_equals(client.getResponseHeader("x-request-content-length"), "NO")
             assert_equals(client.getResponseHeader("x-request-method"), method)
             assert_equals(client.responseText, "")
             assert_array_equals(events, [])
index e155d0142b9d9feb4d7c0bef5d72043fa23d2a3a..60b03670e1073b43b982a27bf07ac6a3716997b6 100644 (file)
@@ -1,4 +1,4 @@
 
 PASS XMLHttpRequest: send() - non-empty data argument and GET/HEAD (GET) 
-PASS XMLHttpRequest: send() - non-empty data argument and GET/HEAD (HEAD) 
+FAIL XMLHttpRequest: send() - non-empty data argument and GET/HEAD (HEAD) assert_equals: expected "NO" but got "0"
 
index bc17cd61a41b934e526794ddfe113628be561820..f3b8cef3555a44d09033e341490604c48688132a 100644 (file)
           client.upload.addEventListener('loadend', logEvt)
           client.upload.addEventListener('loadstart', logEvt)
 
-          if (method === "HEAD") {
-            // Fetch 4.4.3 --- Set Content-Length to 0 if method is HEAD and
-            // request's body is null.
-            assert_equals(client.getResponseHeader("x-request-content-length"), "0")
-          } else {
-            assert_equals(client.getResponseHeader("x-request-content-length"), "NO")
-          }
+          assert_equals(client.getResponseHeader("x-request-content-length"), "NO")
           assert_equals(client.getResponseHeader("x-request-method"), method)
           assert_equals(client.responseText, "")
           assert_array_equals(events, [])
index 0cc83d4a0b756227d81a6940a5df41968790fcbc..53d467b17f38976c89be336f87b471fa1017b42d 100644 (file)
@@ -1,4 +1,8 @@
 
-PASS No content type 
-PASS Explicit content type 
+PASS No content type (POST) 
+PASS No content type (PUT) 
+FAIL No content type (HEAD) assert_equals: expected "NO" but got "0"
+PASS Explicit content type (POST) 
+PASS Explicit content type (PUT) 
+FAIL Explicit content type (HEAD) assert_equals: expected "NO" but got "0"
 
index 11ac824f4dd688b5daa4250bd2fbe0f1ab64c403..d757cb30a9fa36fb7bfd3c34fe44097d768909b5 100644 (file)
@@ -9,24 +9,32 @@
   <body>
     <div id="log"></div>
     <script>
-      test(function() {
+      function noContentTypeTest(method) {
         var client = new XMLHttpRequest()
-        client.open("POST", "resources/content.py", false)
+        client.open(method, "resources/content.py", false)
         client.upload.onloadstart = function(){assert_unreached('this event should not fire for null')}
         client.send(null)
-        assert_equals(client.getResponseHeader("x-request-content-length"), "0")
+        var expectedLength = method == "HEAD" ? "NO" : "0";
+        assert_equals(client.getResponseHeader("x-request-content-length"), expectedLength)
         assert_equals(client.getResponseHeader("x-request-content-type"), "NO")
-      }, "No content type")
+      }
+      test(function() { noContentTypeTest("POST"); }, "No content type (POST)");
+      test(function() { noContentTypeTest("PUT"); }, "No content type (PUT)");
+      test(function() { noContentTypeTest("HEAD"); }, "No content type (HEAD)");
 
-      test(function() {
+      function explicitContentTypeTest(method) {
         var client = new XMLHttpRequest()
-        client.open("POST", "resources/content.py", false)
+        client.open(method, "resources/content.py", false)
         var content_type = 'application/x-foo'
         client.setRequestHeader('Content-Type', content_type)
         client.send(null)
-        assert_equals(client.getResponseHeader("x-request-content-length"), "0")
+        var expectedLength = method == "HEAD" ? "NO" : "0";
+        assert_equals(client.getResponseHeader("x-request-content-length"), expectedLength)
         assert_equals(client.getResponseHeader("x-request-content-type"), content_type)
-      }, "Explicit content type")
+      }
+      test(function() { explicitContentTypeTest("POST"); }, "Explicit content type (POST)");
+      test(function() { explicitContentTypeTest("PUT"); }, "Explicit content type (PUT)");
+      test(function() { explicitContentTypeTest("HEAD"); }, "Explicit content type (HEAD)");
     </script>
   </body>
 </html>
index 96b8f938903ee44a4a0990ebd878e33b41bb60e0..c491ccb29e5e60759eb0ab04f2784268d16bb871 100644 (file)
@@ -1,6 +1,37 @@
+CONSOLE MESSAGE: line 26: ArrayBuffer is deprecated in XMLHttpRequest.send(). Use ArrayBufferView instead.
+CONSOLE MESSAGE: line 26: ArrayBuffer is deprecated in XMLHttpRequest.send(). Use ArrayBufferView instead.
+CONSOLE MESSAGE: line 26: ArrayBuffer is deprecated in XMLHttpRequest.send(). Use ArrayBufferView instead.
 
-PASS XMLHttpRequest: setRequestHeader() - Content-Type header () 
-PASS XMLHttpRequest: setRequestHeader() - Content-Type header ( ) 
-PASS XMLHttpRequest: setRequestHeader() - Content-Type header (null) 
-PASS XMLHttpRequest: setRequestHeader() - Content-Type header (undefined) 
+PASS setRequestHeader("") sends a blank string 
+PASS setRequestHeader(" ") sends the string " " 
+PASS setRequestHeader(null) sends the string "null" 
+PASS setRequestHeader(undefined) sends the string "undefined" 
+PASS String request has correct default Content-Type of "text/plain;charset=UTF-8" 
+PASS String request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8 
+PASS XML Document request respects setRequestHeader("") 
+PASS XML Document request has correct default Content-Type of "application/xml;charset=UTF-8" 
+FAIL XML Document request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8 assert_equals: expected "content-type: application/xhtml+xml;charset=utf-8" but got "content-type: application/xhtml+xml;charset=ascii"
+PASS HTML Document request respects setRequestHeader("") 
+PASS HTML Document request has correct default Content-Type of "text/html;charset=UTF-8" 
+FAIL HTML Document request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8 assert_equals: expected "content-type: text/html+junk;charset=utf-8" but got "content-type: text/html+junk;charset=ascii"
+PASS Blob request respects setRequestHeader("") to be specified 
+FAIL Blob request with unset type sends no Content-Type without setRequestHeader() call assert_equals: expected "" but got "content-type: "
+PASS Blob request with unset type keeps setRequestHeader() Content-Type and charset 
+PASS Blob request with set type uses that it for Content-Type unless setRequestHeader() 
+PASS Blob request with set type keeps setRequestHeader() Content-Type and charset 
+PASS ArrayBuffer request respects setRequestHeader("") 
+FAIL ArrayBuffer request sends no Content-Type without setRequestHeader() call assert_equals: expected "" but got "content-type: application/x-www-form-urlencoded"
+PASS ArrayBuffer request keeps setRequestHeader() Content-Type and charset 
+PASS ArrayBufferView request respects setRequestHeader("") 
+FAIL ArrayBufferView request sends no Content-Type without setRequestHeader() call assert_equals: expected "" but got "content-type: application/x-www-form-urlencoded"
+PASS ArrayBufferView request keeps setRequestHeader() Content-Type and charset 
+PASS FormData request respects setRequestHeader("") 
+PASS FormData request has correct default Content-Type of "multipart/form-data;boundary=_" 
+PASS FormData request keeps setRequestHeader() Content-Type and charset 
+FAIL URLSearchParams respects setRequestHeader("") assert_unreached: Skipping test as could not create a URLSearchParams;  Reached unreachable code
+FAIL URLSearchParams request has correct default Content-Type of "application/x-www-form-urlencoded;charset=UTF-8" assert_unreached: Skipping test as could not create a URLSearchParams;  Reached unreachable code
+FAIL URLSearchParams request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8 assert_unreached: Skipping test as could not create a URLSearchParams;  Reached unreachable code
+PASS ReadableStream request respects setRequestHeader("") 
+FAIL ReadableStream request with under type sends no Content-Type without setRequestHeader() call assert_equals: expected "" but got "content-type: text/plain;charset=utf-8"
+FAIL ReadableStream request keeps setRequestHeader() Content-Type and charset assert_equals: expected "content-type: application/xml;charset=ascii" but got "content-type: application/xml;charset=utf-8"
 
index a648efa64ca67a7892a8af7c2073c2c0281a5fd9..64a72927a6dd31ecd5745963632ac00be1ca491a 100644 (file)
   <body>
     <div id="log"></div>
     <script>
-      function request(value) {
+      function request(inputGenerator, headersToSend, expectedType, title) {
         test(function() {
+          try {
+            var toSend = inputGenerator();
+          } catch(e) {
+            assert_unreached("Skipping test as could not create a " + inputGenerator.name.replace("_", "") + "; ");
+          }
           var client = new XMLHttpRequest()
           client.open("POST", "resources/inspect-headers.py?filter_name=Content-Type", false)
-          client.setRequestHeader('Content-Type', value)
-          client.send("")
-          assert_equals(client.responseText, 'content-type: '+ String(value ? value.trim() : value).toLowerCase()+'\n' )
-        }, document.title + " (" + value + ")")
+          for(header in headersToSend) {
+            if (headersToSend.hasOwnProperty(header)) {
+              client.setRequestHeader(header, headersToSend[header]);
+            }
+          }
+          client.send(toSend)
+
+          var responseType = client.responseText.replace("\n", "").replace("; ", ";").toLowerCase(); // don't care about case or space after semicolon for charset
+          if (expectedType === undefined || expectedType === null) {
+            assert_equals(responseType, "");
+          } else if (expectedType instanceof RegExp) {
+            if (!expectedType.ignoreCase) expectedType = new RegExp(expectedType, "i"); // always ignore case; the regex itself will have to remember to handle the optional space after the semicolon for charset
+            assert_regexp_match(responseType, expectedType);
+          } else {
+            expectedType = "content-type: " + String(expectedType ? expectedType.trim().replace("; ", ";") : expectedType).toLowerCase()
+            assert_equals(responseType, expectedType);
+          }
+        }, title)
       }
-      request("")
-      request(" ")
-      request(null)
-      request(undefined)
+      request(
+        function _String() { return ""; },
+        {"Content-Type": ""},
+        "",
+        'setRequestHeader("") sends a blank string'
+      )
+      request(
+        function _String() { return ""; },
+        {"Content-Type": " "},
+        " ",
+        'setRequestHeader(" ") sends the string " "'
+      )
+      request(
+        function _String() { return ""; },
+        {"Content-Type": null},
+        "null",
+        'setRequestHeader(null) sends the string "null"'
+      )
+      request(
+        function _String() { return ""; },
+        {"Content-Type": undefined},
+        "undefined",
+        'setRequestHeader(undefined) sends the string "undefined"'
+      )
+      request(
+        function _String() { return "test"; },
+        {},
+        "text/plain;charset=UTF-8",
+        'String request has correct default Content-Type of "text/plain;charset=UTF-8"'
+      )
+      request(
+        function _String() { return "test()"; },
+        {"Content-Type": "text/javascript;charset=ASCII"},
+        "text/javascript;charset=UTF-8",
+        "String request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8"
+      )
+      request(
+        function _XMLDocument() { return new DOMParser().parseFromString("<xml/>", "application/xml"); },
+        {"Content-Type": ""},
+        "",
+        'XML Document request respects setRequestHeader("")'
+      )
+      request(
+        function _XMLDocument() { return new DOMParser().parseFromString("<xml/>", "application/xml"); },
+        {},
+        "application/xml;charset=UTF-8",
+        'XML Document request has correct default Content-Type of "application/xml;charset=UTF-8"'
+      )
+      request(
+        function _XMLDocument() { return new DOMParser().parseFromString("<xml/>", "application/xml"); },
+        {"Content-Type": "application/xhtml+xml;charset=ASCII"},
+        "application/xhtml+xml;charset=UTF-8",
+        "XML Document request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8"
+      )
+      request(
+        function _HTMLDocument() { return new DOMParser().parseFromString("<html></html>", "text/html"); },
+        {"Content-Type": ""},
+        "",
+        'HTML Document request respects setRequestHeader("")'
+      )
+      request(
+        function _HTMLDocument() { return new DOMParser().parseFromString("<html></html>", "text/html"); },
+        {},
+        "text/html;charset=UTF-8",
+        'HTML Document request has correct default Content-Type of "text/html;charset=UTF-8"'
+      )
+      request(
+        function _HTMLDocument() { return new DOMParser().parseFromString("<html></html>", "text/html"); },
+        {"Content-Type": "text/html+junk;charset=ASCII"},
+        "text/html+junk;charset=UTF-8",
+        "HTML Document request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8"
+      )
+      request(
+        function _Blob() { return new Blob(["test"]); },
+        {"Content-Type": ""},
+        "",
+        'Blob request respects setRequestHeader("") to be specified'
+      )
+      request(
+        function _Blob() { return new Blob(["test"]); },
+        {},
+        undefined,
+        "Blob request with unset type sends no Content-Type without setRequestHeader() call"
+      )
+      request(
+        function _Blob() { return new Blob(["test"]); },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=ASCII",
+        "Blob request with unset type keeps setRequestHeader() Content-Type and charset"
+      )
+      request(
+        function _Blob() { return new Blob(["<xml/>"], {type : "application/xml;charset=ASCII"}); },
+        {},
+        "application/xml;charset=ASCII",
+        "Blob request with set type uses that it for Content-Type unless setRequestHeader()"
+      )
+      request(
+        function _Blob() { return new Blob(["<xml/>"], {type : "application/xml;charset=UTF8"}); },
+        {"Content-Type": "application/xml+junk;charset=ASCII"},
+        "application/xml+junk;charset=ASCII",
+        "Blob request with set type keeps setRequestHeader() Content-Type and charset"
+      )
+      request(
+        function _ArrayBuffer() { return new ArrayBuffer(10); },
+        {"Content-Type": ""},
+        "",
+        'ArrayBuffer request respects setRequestHeader("")'
+      )
+      request(
+        function _ArrayBuffer() { return new ArrayBuffer(10); },
+        {},
+        undefined,
+        "ArrayBuffer request sends no Content-Type without setRequestHeader() call"
+      )
+      request(
+        function _ArrayBuffer() { return new ArrayBuffer(10); },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=ASCII",
+        "ArrayBuffer request keeps setRequestHeader() Content-Type and charset"
+      )
+      request(
+        function _Uint8Array() { return new Uint8Array(new ArrayBuffer(10)); },
+        {"Content-Type": ""},
+        "",
+        'ArrayBufferView request respects setRequestHeader("")'
+      )
+      request(
+        function _Uint8Array() { return new Uint8Array(new ArrayBuffer(10)); },
+        {},
+        undefined,
+        "ArrayBufferView request sends no Content-Type without setRequestHeader() call"
+      )
+      request(
+        function _Uint8Array() { return new Uint8Array(new ArrayBuffer(10)); },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=ASCII",
+        "ArrayBufferView request keeps setRequestHeader() Content-Type and charset"
+      )
+      request(
+        function _FormData() { return new FormData(); },
+        {"Content-Type": ""},
+        "",
+        'FormData request respects setRequestHeader("")'
+      )
+      request(
+        function _FormData() { return new FormData(); },
+        {},
+        /multipart\/form-data;boundary=(.*)/,
+        'FormData request has correct default Content-Type of "multipart\/form-data;boundary=_"'
+      )
+      request(
+        function _FormData() { return new FormData(); },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=ASCII",
+        "FormData request keeps setRequestHeader() Content-Type and charset"
+      )
+      request(
+        function _URLSearchParams() { return new URLSearchParams("q=testQ&topic=testTopic") },
+        {"Content-Type": ""},
+        "",
+        'URLSearchParams respects setRequestHeader("")'
+      )
+      request(
+        function _URLSearchParams() { return new URLSearchParams("q=testQ&topic=testTopic") },
+        {},
+        "application/x-www-form-urlencoded;charset=UTF-8",
+        'URLSearchParams request has correct default Content-Type of "application/x-www-form-urlencoded;charset=UTF-8"'
+      )
+      request(
+        function _URLSearchParams() { return new URLSearchParams("q=testQ&topic=testTopic") },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=UTF-8",
+        "URLSearchParams request keeps setRequestHeader() Content-Type, with charset adjusted to UTF-8"
+        // the default Content-Type for URLSearchParams has a charset specified (utf-8) in
+        // https://fetch.spec.whatwg.org/#bodyinit, so the user's must be changed to match it
+        // as per https://xhr.spec.whatwg.org/#the-send%28%29-method step 4.
+      )
+      request(
+        function _ReadableStream() { return new ReadableStream() },
+        {"Content-Type": ""},
+        "",
+        'ReadableStream request respects setRequestHeader("")'
+      )
+      request(
+        function _ReadableStream() { return new ReadableStream() },
+        {},
+        undefined,
+        "ReadableStream request with under type sends no Content-Type without setRequestHeader() call"
+      )
+      request(
+        function _ReadableStream() { return new ReadableStream() },
+        {"Content-Type": "application/xml;charset=ASCII"},
+        "application/xml;charset=ASCII",
+        "ReadableStream request keeps setRequestHeader() Content-Type and charset"
+      )
     </script>
   </body>
 </html>
index fa9ed430d4fc11e7c349aa962cc9128b6324e0eb..b2bcead82e0420387ab2299482ab2e12176a9009 100644 (file)
@@ -17,9 +17,7 @@ None
 List of files:
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/FormData-append.html
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/OWNERS
-/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.html
-/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js
-/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.worker.js
+/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.any.js
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/abort-after-receive.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/abort-after-send.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/abort-after-timeout.htm
@@ -63,6 +61,7 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/getresponseheader-server-date.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/getresponseheader-special-characters.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/getresponseheader-unsent-opened-state.htm
+/LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/headers-normalize-response.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/interfaces.html
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/open-after-abort.htm
 /LayoutTests/imported/w3c/web-platform-tests/XMLHttpRequest/open-after-setrequestheader.htm
diff --git a/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once-expected.txt
new file mode 100644 (file)
index 0000000..1ec7c17
--- /dev/null
@@ -0,0 +1,5 @@
+
+PASS Once listener should be invoked only once 
+PASS Once listener should be invoked only once even if the event is nested 
+PASS Once listener should be added / removed like normal listeners 
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once.html b/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once.html
new file mode 100644 (file)
index 0000000..ae75070
--- /dev/null
@@ -0,0 +1,81 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>AddEventListenerOptions.once</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="help" href="https://dom.spec.whatwg.org/#dom-addeventlisteneroptions-once">
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<div id="log"></div>
+<script>
+
+test(function() {
+  var invoked_once = false;
+  var invoked_normal = false;
+  function handler_once() {
+    invoked_once = true;
+  }
+  function handler_normal() {
+    invoked_normal = true;
+  }
+
+  document.addEventListener('test', handler_once, {once: true});
+  document.addEventListener('test', handler_normal);
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_once, true, "Once handler should be invoked");
+  assert_equals(invoked_normal, true, "Normal handler should be invoked");
+
+  invoked_once = false;
+  invoked_normal = false;
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_once, false, "Once handler shouldn't be invoked again");
+  assert_equals(invoked_normal, true, "Normal handler should be invoked again");
+  document.removeEventListener('test', handler_normal);
+}, "Once listener should be invoked only once");
+
+test(function() {
+  var invoked_count = 0;
+  function handler() {
+    invoked_count++;
+    if (invoked_count == 1)
+      document.dispatchEvent(new Event('test'));
+  }
+  document.addEventListener('test', handler, {once: true});
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_count, 1, "Once handler should only be invoked once");
+
+  invoked_count = 0;
+  function handler2() {
+    invoked_count++;
+    if (invoked_count == 1)
+      document.addEventListener('test', handler2, {once: true});
+    if (invoked_count <= 2)
+      document.dispatchEvent(new Event('test'));
+  }
+  document.addEventListener('test', handler2, {once: true});
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_count, 2, "Once handler should only be invoked once after each adding");
+}, "Once listener should be invoked only once even if the event is nested");
+
+test(function() {
+  var invoked_count = 0;
+  function handler() {
+    invoked_count++;
+  }
+
+  document.addEventListener('test', handler, {once: true});
+  document.addEventListener('test', handler);
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_count, 1, "The handler should only be added once");
+
+  invoked_count = 0;
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_count, 0, "The handler was added as a once listener");
+
+  invoked_count = 0;
+  document.addEventListener('test', handler, {once: true});
+  document.removeEventListener('test', handler);
+  document.dispatchEvent(new Event('test'));
+  assert_equals(invoked_count, 0, "The handler should have been removed");
+}, "Once listener should be added / removed like normal listeners");
+
+</script>
index 571cfa585ac9ec46f0fa7792f74ea3cfedcba123..0da5a24c00440a8f5417916db2b4809875c21e6c 100644 (file)
@@ -15,6 +15,7 @@ Property values requiring vendor prefixes:
 None
 ------------------------------------------------------------------------
 List of files:
+/LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-once.html
 /LayoutTests/imported/w3c/web-platform-tests/dom/events/AddEventListenerOptions-passive.html
 /LayoutTests/imported/w3c/web-platform-tests/dom/events/CustomEvent.html
 /LayoutTests/imported/w3c/web-platform-tests/dom/events/Event-constants.html
diff --git a/LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration-expected.txt
new file mode 100644 (file)
index 0000000..273e79d
--- /dev/null
@@ -0,0 +1,3 @@
+
+FAIL DOMTokenList iteration: keys, values, etc. assert_array_equals: lengths differ, expected 3 got 2
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration.html b/LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration.html
new file mode 100644 (file)
index 0000000..1911f7b
--- /dev/null
@@ -0,0 +1,48 @@
+<!doctype html>
+<meta charset=utf-8>
+<title>DOMTokenList iteration: keys, values, etc.</title>
+<script src=/resources/testharness.js></script>
+<script src=/resources/testharnessreport.js></script>
+<span class="   a  a b "></span>
+<script>
+  test(function() {
+    var list = document.querySelector("span").classList;
+    assert_array_equals([...list], ["a", "a", "b"]);
+
+    var keys = list.keys();
+    assert_false(keys instanceof Array);
+    keys = [...keys];
+    assert_array_equals(keys, [0, 1, 2]);
+
+    var values = list.values();
+    assert_false(values instanceof Array);
+    values = [...values];
+    assert_array_equals(values, ["a", "a", "b"]);
+
+    var entries = list.entries();
+    assert_false(entries instanceof Array);
+    entries = [...entries];
+    assert_equals(entries.length, keys.length);
+    assert_equals(entries.length, values.length);
+    for (var i = 0; i < entries.length; ++i) {
+      assert_array_equals(entries[i], [keys[i], values[i]]);
+    }
+
+    var cur = 0;
+    var thisObj = {};
+    list.forEach(function(value, key, listObj) {
+      assert_equals(listObj, list);
+      assert_equals(this, thisObj);
+      assert_equals(value, values[cur]);
+      assert_equals(key, keys[cur]);
+      cur++;
+    }, thisObj);
+    assert_equals(cur, entries.length);
+
+    assert_equals(list[Symbol.iterator], Array.prototype[Symbol.iterator]);
+    assert_equals(list.keys, Array.prototype.keys);
+    assert_equals(list.values, Array.prototype.values);
+    assert_equals(list.entries, Array.prototype.entries);
+    assert_equals(list.forEach, Array.prototype.forEach);
+  });
+</script>
index ddee6865d91c4217ff53f62c8302c71f312969a2..4e136745545070cf8fab0d3bdba4e51a5c6b5e05 100644 (file)
@@ -16,5 +16,6 @@ None
 ------------------------------------------------------------------------
 List of files:
 /LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-coverage-for-attributes.html
+/LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-iteration.html
 /LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-stringifier.html
 /LayoutTests/imported/w3c/web-platform-tests/dom/lists/DOMTokenList-value.html
index 8fc352498a7b3527f012e58c61f08c6b05bf2f37..ead9d03a5c47f74d68becba3e7fa6d94fcbced1e 100644 (file)
@@ -3,4 +3,5 @@ PASS Caching of Node.childNodes
 PASS Node.childNodes on an Element. 
 PASS Node.childNodes on a DocumentFragment. 
 PASS Node.childNodes on a Document. 
+PASS Iterator behavior of Node.childNodes 
 
index d08dd2e1fa551acd895e88c82d50652cd448f0ad..8bd1f250e472c0d27cffbb92e3d69688e7df939f 100644 (file)
@@ -45,4 +45,53 @@ test(function() {
 test(function() {
   check_parent_node(new Document());
 }, "Node.childNodes on a Document.");
+
+test(function() {
+  var node = document.createElement("div");
+  var kid1 = document.createElement("p");
+  var kid2 = document.createTextNode("hey");
+  var kid3 = document.createElement("span");
+  node.appendChild(kid1);
+  node.appendChild(kid2);
+  node.appendChild(kid3);
+
+  var list = node.childNodes;
+  assert_array_equals([...list], [kid1, kid2, kid3]);
+
+  var keys = list.keys();
+  assert_false(keys instanceof Array);
+  keys = [...keys];
+  assert_array_equals(keys, [0, 1, 2]);
+
+  var values = list.values();
+  assert_false(values instanceof Array);
+  values = [...values];
+  assert_array_equals(values, [kid1, kid2, kid3]);
+
+  var entries = list.entries();
+  assert_false(entries instanceof Array);
+  entries = [...entries];
+  assert_equals(entries.length, keys.length);
+  assert_equals(entries.length, values.length);
+  for (var i = 0; i < entries.length; ++i) {
+    assert_array_equals(entries[i], [keys[i], values[i]]);
+  }
+
+  var cur = 0;
+  var thisObj = {};
+  list.forEach(function(value, key, listObj) {
+    assert_equals(listObj, list);
+    assert_equals(this, thisObj);
+    assert_equals(value, values[cur]);
+    assert_equals(key, keys[cur]);
+    cur++;
+  }, thisObj);
+  assert_equals(cur, entries.length);
+
+  assert_equals(list[Symbol.iterator], Array.prototype[Symbol.iterator]);
+  assert_equals(list.keys, Array.prototype.keys);
+  assert_equals(list.values, Array.prototype.values);
+  assert_equals(list.entries, Array.prototype.entries);
+  assert_equals(list.forEach, Array.prototype.forEach);
+}, "Iterator behavior of Node.childNodes");
 </script>
index d277b0ef4650686916e3a7d1f56bbcda33d37f0d..be0bbf71b1d67e816c5634bf928c429a87207763 100644 (file)
@@ -1,6 +1,7 @@
 
 FAIL Fetch with GET assert_equals: Request has header origin: http://localhost:8800 expected (string) "http://localhost:8800" but got (object) null
 FAIL Fetch with HEAD assert_equals: Request has header origin: http://localhost:8800 expected (string) "http://localhost:8800" but got (object) null
+FAIL Fetch with HEAD with body promise_test: Unhandled rejection with value: object "TypeError: Type error"
 PASS Fetch with PUT without body 
 PASS Fetch with PUT with body 
 PASS Fetch with POST without body 
index d277b0ef4650686916e3a7d1f56bbcda33d37f0d..be0bbf71b1d67e816c5634bf928c429a87207763 100644 (file)
@@ -1,6 +1,7 @@
 
 FAIL Fetch with GET assert_equals: Request has header origin: http://localhost:8800 expected (string) "http://localhost:8800" but got (object) null
 FAIL Fetch with HEAD assert_equals: Request has header origin: http://localhost:8800 expected (string) "http://localhost:8800" but got (object) null
+FAIL Fetch with HEAD with body promise_test: Unhandled rejection with value: object "TypeError: Type error"
 PASS Fetch with PUT without body 
 PASS Fetch with PUT with body 
 PASS Fetch with POST without body 
index 2ddce2af5f6d5c91469f4645f90c8704136ead63..785576e0e3962365f0cae3ca72f9b62acadd2af9 100644 (file)
@@ -23,7 +23,8 @@ function requestHeaders(desc, url, method, body, expectedOrigin, expectedContent
 var url = RESOURCES_DIR + "inspect-headers.py"
 
 requestHeaders("Fetch with GET", url, "GET", null, location.origin, null);
-requestHeaders("Fetch with HEAD", url, "HEAD", null, location.origin, "0");
+requestHeaders("Fetch with HEAD", url, "HEAD", null, location.origin, null);
+requestHeaders("Fetch with HEAD with body", url, "HEAD", "Request's body", location.origin, "14");
 requestHeaders("Fetch with PUT without body", url, "POST", null, location.origin, "0");
 requestHeaders("Fetch with PUT with body", url, "PUT", "Request's body", location.origin, "14");
 requestHeaders("Fetch with POST without body", url, "POST", null, location.origin, "0");
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer-expected.txt
new file mode 100644 (file)
index 0000000..21e9510
--- /dev/null
@@ -0,0 +1,4 @@
+
+PASS Fetch: fetch() respects Request referrer value 
+PASS Fetch: fetch() respects Request referrer value 1 
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.html b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.html
new file mode 100644 (file)
index 0000000..dd89561
--- /dev/null
@@ -0,0 +1,13 @@
+<!doctype html>
+<html>
+  <head>
+    <meta charset="utf-8">
+    <title>Fetch: fetch() respects Request referrer value</title>
+    <script src="/resources/testharness.js"></script>
+    <script src="/resources/testharnessreport.js"></script>
+  </head>
+  <body>
+    <script src="../resources/utils.js"></script>
+    <script src="request-referrer.js"></script>
+  </body>
+</html>
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.js b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.js
new file mode 100644 (file)
index 0000000..cc5cc8e
--- /dev/null
@@ -0,0 +1,28 @@
+if (this.document === undefined) {
+  importScripts("/resources/testharness.js");
+  importScripts("../resources/utils.js");
+}
+
+function testReferrer(referrer, expected) {
+  promise_test(function(test) {
+    var url = RESOURCES_DIR + "inspect-headers.py?headers=referer"
+    var req = new Request(url, { referrer: referrer });
+    return fetch(req).then(function(resp) {
+      var actual = resp.headers.get("x-request-referer");
+      if (expected) {
+        assert_equals(actual, expected, "request's referer should be: " + expected);
+        return;
+      }
+      if (actual) {
+        assert_equals(actual, "", "request's referer should be empty");
+      }
+    });
+  });
+}
+
+testReferrer("about:client", window.location.href);
+
+var fooURL = new URL("./foo", window.location).href;
+testReferrer(fooURL, fooURL);
+
+done();
index b57bd935da761fef9d4555fdeb36b35b9b0e5fe0..9bd59e4dd1dac349df3b8fe494416f7cc65ee5d9 100644 (file)
@@ -36,6 +36,8 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers.js
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.html
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-referrer.js
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/response-url-worker.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/response-url.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/response-url.js
index 34988783581fbf2a1cce46cdcd017c2fd0665887..25537d60f6f2d2e0f98d6009b638d61205b65c03 100644 (file)
@@ -1,5 +1,3 @@
-CONSOLE MESSAGE: Unrecognized Content-Security-Policy directive 'referrer'.
-
 
 PASS Request's referrer is empty 
 
index fe5655b72941c2c9b54f258df04fedcb36e8e0e1..da9019b4da6eceffac751318f2521162e4b334a8 100644 (file)
@@ -1,5 +1,3 @@
-CONSOLE MESSAGE: Unrecognized Content-Security-Policy directive 'referrer'.
-
 
 FAIL Request's referrer is origin assert_equals: request's referrer is http://localhost:8800/ expected "http://localhost:8800/" but got "http://localhost:8800/fetch/api/policies/referrer-origin.html"
 PASS Throw a TypeError referrer is not same-origin with origin 
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-expected.txt
new file mode 100644 (file)
index 0000000..5d72c35
--- /dev/null
@@ -0,0 +1,3 @@
+
+FAIL Request's referrer is origin assert_equals: request's referrer is http://localhost:8800/ expected "http://localhost:8800/" but got "http://localhost:8800/fetch/api/policies/referrer-origin-when-cross-origin.html"
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker-expected.txt
new file mode 100644 (file)
index 0000000..966feff
--- /dev/null
@@ -0,0 +1,3 @@
+
+FAIL Request's referrer is origin assert_equals: request's referrer is http://localhost:8800/ expected "http://localhost:8800/" but got "http://localhost:8800/fetch/api/policies/referrer-origin-when-cross-origin.js?pipe=sub"
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html
new file mode 100644 (file)
index 0000000..f95ae8c
--- /dev/null
@@ -0,0 +1,16 @@
+<!doctype html>
+<html>
+  <head>
+    <meta charset="utf-8">
+    <title>Fetch in worker: referrer with origin-when-cross-origin policy</title>
+    <meta name="help" href="https://fetch.spec.whatwg.org/#main-fetch">
+    <meta name="help" href="https://fetch.spec.whatwg.org/#http-network-or-cache-fetch">
+    <script src="/resources/testharness.js"></script>
+    <script src="/resources/testharnessreport.js"></script>
+  </head>
+  <body>
+    <script>
+      fetch_tests_from_worker(new Worker("referrer-origin-when-cross-origin.js?pipe=sub"));
+    </script>
+  </body>
+</html>
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html
new file mode 100644 (file)
index 0000000..18de736
--- /dev/null
@@ -0,0 +1,15 @@
+<!doctype html>
+<html>
+  <head>
+    <meta charset="utf-8">
+    <title>Fetch: referrer with origin-when-cross-origin policy</title>
+    <meta name="help" href="https://fetch.spec.whatwg.org/#main-fetch">
+    <meta name="help" href="https://fetch.spec.whatwg.org/#http-network-or-cache-fetch">
+    <script src="/resources/testharness.js"></script>
+    <script src="/resources/testharnessreport.js"></script>
+  </head>
+  <body>
+    <script src="../resources/utils.js"></script>
+    <script src="referrer-origin-when-cross-origin.js?pipe=sub"></script>
+  </body>
+</html>
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers
new file mode 100644 (file)
index 0000000..ad768e6
--- /dev/null
@@ -0,0 +1 @@
+Referrer-Policy: origin-when-cross-origin
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js
new file mode 100644 (file)
index 0000000..2baf7d1
--- /dev/null
@@ -0,0 +1,16 @@
+if (this.document === undefined) {
+  importScripts("/resources/testharness.js");
+  importScripts("../resources/utils.js");
+}
+
+var referrerOrigin = "http://{{host}}:{{ports[http][0]}}/";
+var fetchedUrl = "http://{{host}}:{{ports[http][1]}}" + dirname(location.pathname) + RESOURCES_DIR + "inspect-headers.py?cors&headers=referer";
+
+promise_test(function(test) {
+  return fetch(fetchedUrl).then(function(resp) {
+    assert_equals(resp.status, 200, "HTTP status is 200");
+    assert_equals(resp.headers.get("x-request-referer"), referrerOrigin, "request's referrer is " + referrerOrigin);
+  });
+}, "Request's referrer is origin");
+
+done();
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers
new file mode 100644 (file)
index 0000000..ad768e6
--- /dev/null
@@ -0,0 +1 @@
+Referrer-Policy: origin-when-cross-origin
index 348df38bbf63f275be8c9207422e0996ce9a9ee0..e8193924bfd8d62fee919a61d6186cf9942802e1 100644 (file)
@@ -1,5 +1,3 @@
-CONSOLE MESSAGE: Unrecognized Content-Security-Policy directive 'referrer'.
-
 
 FAIL Request's referrer is origin assert_equals: request's referrer is http://localhost:8800/ expected "http://localhost:8800/" but got "http://localhost:8800/fetch/api/policies/referrer-origin.js?pipe=sub"
 PASS Throw a TypeError referrer is not same-origin with origin 
index 9bb592a867d2097adcbc922336bcfaec8d841a2f..5b29739bbdde3ae5ad83bdaed1f69ea966cf8353 100644 (file)
@@ -1 +1 @@
-Content-Security-Policy: referrer origin;
\ No newline at end of file
+Referrer-Policy: origin
index a87896ea483e5e1c1d603146297971c028fedaeb..d34afe71c462f8721ca10a1c5da45ad5c2de81c1 100644 (file)
@@ -1,5 +1,3 @@
-CONSOLE MESSAGE: Unrecognized Content-Security-Policy directive 'referrer'.
-
 
 PASS Request's referrer is the full url of current document/worker 
 
index a87896ea483e5e1c1d603146297971c028fedaeb..d34afe71c462f8721ca10a1c5da45ad5c2de81c1 100644 (file)
@@ -1,5 +1,3 @@
-CONSOLE MESSAGE: Unrecognized Content-Security-Policy directive 'referrer'.
-
 
 PASS Request's referrer is the full url of current document/worker 
 
index 4f129be9114d692b3587603afdf4e632addcfed5..27e1f23f4b37fd29a006c31464e3dc615026bc20 100644 (file)
@@ -25,6 +25,11 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer.html.headers
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer.js
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-no-referrer.js.headers
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin-worker.html
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.html.headers
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js
+/LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-when-cross-origin.js.headers
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin-worker.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin.html
 /LayoutTests/imported/w3c/web-platform-tests/fetch/api/policies/referrer-origin.html.headers
index 5e779cc5a3215ebcd42430919a417952e799e574..5ad440ee5ed2b8b94d51672abf405d4385401500 100644 (file)
@@ -37,12 +37,12 @@ PASS RequestCache "only-if-cached" (with "same-origin") does not follow redirect
 PASS RequestCache "only-if-cached" (with "same-origin") does not follow redirects across origins and rejects with date and fresh response 
 PASS RequestCache "only-if-cached" (with "same-origin") does not follow redirects across origins and rejects with Etag and stale response 
 PASS RequestCache "only-if-cached" (with "same-origin") does not follow redirects across origins and rejects with date and stale response 
-FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.5142751701087829\""
-FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with date and stale response assert_equals: expected (undefined) undefined but got (string) "Wed, 27 Jul 2016 15:14:16 GMT"
+FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.9287170582472863\""
+FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with date and stale response assert_equals: expected (undefined) undefined but got (string) "Tue, 02 Aug 2016 10:05:20 GMT"
 FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with Etag and fresh response assert_equals: expected 2 but got 1
 FAIL RequestCache "no-store" mode does not check the cache for previously cached content and goes to the network regardless with date and fresh response assert_equals: expected 2 but got 1
-FAIL RequestCache "no-store" mode does not store the response in the cache with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.8439838765231941\""
-FAIL RequestCache "no-store" mode does not store the response in the cache with date and stale response assert_equals: expected (undefined) undefined but got (string) "Wed, 27 Jul 2016 15:14:16 GMT"
+FAIL RequestCache "no-store" mode does not store the response in the cache with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.08585050505689817\""
+FAIL RequestCache "no-store" mode does not store the response in the cache with date and stale response assert_equals: expected (undefined) undefined but got (string) "Tue, 02 Aug 2016 10:05:20 GMT"
 FAIL RequestCache "no-store" mode does not store the response in the cache with Etag and fresh response assert_equals: expected 2 but got 1
 FAIL RequestCache "no-store" mode does not store the response in the cache with date and fresh response assert_equals: expected 2 but got 1
 PASS RequestCache "default" mode with an If-Modified-Since header is treated similarly to "no-store" with Etag and stale response 
@@ -89,16 +89,16 @@ PASS Responses with the "Cache-Control: no-store" header are not stored in the c
 PASS Responses with the "Cache-Control: no-store" header are not stored in the cache with date and stale response 
 PASS Responses with the "Cache-Control: no-store" header are not stored in the cache with Etag and fresh response 
 PASS Responses with the "Cache-Control: no-store" header are not stored in the cache with date and fresh response 
-FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.7100561973865757\""
-FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with date and stale response assert_equals: expected (undefined) undefined but got (string) "Wed, 27 Jul 2016 15:14:16 GMT"
+FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.6811605903969123\""
+FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with date and stale response assert_equals: expected (undefined) undefined but got (string) "Tue, 02 Aug 2016 10:05:20 GMT"
 FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with Etag and fresh response assert_equals: expected 2 but got 1
 FAIL RequestCache "reload" mode does not check the cache for previously cached content and goes to the network regardless with date and fresh response assert_equals: expected 2 but got 1
 PASS RequestCache "reload" mode does store the response in the cache with Etag and stale response 
 PASS RequestCache "reload" mode does store the response in the cache with date and stale response 
 PASS RequestCache "reload" mode does store the response in the cache with Etag and fresh response 
 PASS RequestCache "reload" mode does store the response in the cache with date and fresh response 
-FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.45824924441966697\""
-FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with date and stale response assert_equals: expected (undefined) undefined but got (string) "Wed, 27 Jul 2016 15:14:16 GMT"
+FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with Etag and stale response assert_equals: expected (undefined) undefined but got (string) "\"0.8124005052523855\""
+FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with date and stale response assert_equals: expected (undefined) undefined but got (string) "Tue, 02 Aug 2016 10:05:20 GMT"
 FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with Etag and fresh response assert_equals: expected 2 but got 1
 FAIL RequestCache "reload" mode does store the response in the cache even if a previous response is already stored with date and fresh response assert_equals: expected 2 but got 1
 
diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/resources/get-host-info.sub.js b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/resources/get-host-info.sub.js
deleted file mode 100644 (file)
index 47fdef9..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-// This file is duplicated verbatim from:
-// service-workers/service-worker/resources/get-host-info.sub.js
-// with the rationale that:
-// - it's better to not reinvent this
-// - at the same time, referencing tests deep inside a sibling test group is
-//   not a great idea and copying the file is the lesser evil.
-function get_host_info() {
-  var ORIGINAL_HOST = '127.0.0.1';
-  var REMOTE_HOST = 'localhost';
-  var UNAUTHENTICATED_HOST = 'example.test';
-  var HTTP_PORT = 8000;
-  var HTTPS_PORT = 8443;
-  try {
-    // In W3C test, we can get the hostname and port number in config.json
-    // using wptserve's built-in pipe.
-    // http://wptserve.readthedocs.org/en/latest/pipes.html#built-in-pipes
-    HTTP_PORT = eval('{{ports[http][0]}}');
-    HTTPS_PORT = eval('{{ports[https][0]}}');
-    ORIGINAL_HOST = eval('\'{{host}}\'');
-    REMOTE_HOST = 'www1.' + ORIGINAL_HOST;
-  } catch (e) {
-  }
-  return {
-    HTTP_ORIGIN: 'http://' + ORIGINAL_HOST + ':' + HTTP_PORT,
-    HTTPS_ORIGIN: 'https://' + ORIGINAL_HOST + ':' + HTTPS_PORT,
-    HTTPS_ORIGIN_WITH_CREDS: 'https://foo:bar@' + ORIGINAL_HOST + ':' + HTTPS_PORT,
-    HTTP_REMOTE_ORIGIN: 'http://' + REMOTE_HOST + ':' + HTTP_PORT,
-    HTTPS_REMOTE_ORIGIN: 'https://' + REMOTE_HOST + ':' + HTTPS_PORT,
-    HTTPS_REMOTE_ORIGIN_WITH_CREDS: 'https://foo:bar@' + REMOTE_HOST + ':' + HTTPS_PORT,
-    UNAUTHENTICATED_ORIGIN: 'http://' + UNAUTHENTICATED_HOST + ':' + HTTP_PORT
-  };
-}
index 32a07c197dfffab520860c9da6cf4437a7462d6b..8fb05edc658dd01d478d65393f28a7fc15174ff2 100644 (file)
@@ -3,7 +3,7 @@ import os.path
 def main(request, response):
     type = request.GET.first("type", None)
 
-    body = open(os.path.join(os.path.dirname(__file__), "../../../images/blue96x96.png")).read()
+    body = open(os.path.join(os.path.dirname(__file__), "../../../images/blue96x96.png"), "rb").read()
 
     response.add_required_headers = False
     response.writer.write_status(200)
index 3b8e7b87aa84e19d6df708cde5bcd038bad0a10c..36d9e3671cdc15708cf5decd37f75f283875789e 100644 (file)
@@ -4,5 +4,5 @@ FAIL URL query: ?type= assert_unreached: Unexpected load event Reached unreachab
 FAIL URL query: ?type=x assert_unreached: Unexpected load event Reached unreachable code
 FAIL URL query: ?type=x/x assert_unreached: Unexpected load event Reached unreachable code
 PASS URL query: ?type=text/css 
-FAIL URL query: ?type=text/css;blah assert_equals: expected 2 but got 6
+PASS URL query: ?type=text/css;blah 
 
index 035994b69304446ffed6fa61c2a0da04f3158010..8b1eea6dc5bbc7c6dd0109a21a3e46b8f48941f7 100644 (file)
       var link = document.createElement("link")
       link.rel = "stylesheet"
       link.onerror = t.unreached_func("Unexpected error event")
-      link.onload = t.step_func_done(function(){
-        if(passes[passes.length-1] == urlpart) {
-          assert_equals(document.styleSheets.length, passes.length)
-        }
-      })
+      link.onload = t.step_func_done(function(){})
       link.href = "resources/css.py" + urlpart
       document.body.appendChild(link)
     }, "URL query: " + urlpart)
index dfe4730993b0bb966fdc36a535b22c9c9e5a65e4..88703a604725788561e5c7f88a9ee9575118b648 100644 (file)
@@ -5615,9 +5615,7 @@ PASS Navigator interface: attribute cookieEnabled
 FAIL Navigator interface: operation yieldForStorageUpdates() assert_own_property: interface prototype object missing non-static operation expected property "yieldForStorageUpdates" missing
 PASS Navigator interface: attribute plugins 
 PASS Navigator interface: attribute mimeTypes 
-FAIL Navigator interface: attribute javaEnabled assert_throws: getting property on prototype object must throw TypeError function "function () {
-    [native code]
-}" did not throw
+PASS Navigator interface: operation javaEnabled() 
 PASS Navigator must be primary interface of window.navigator 
 PASS Stringification of window.navigator 
 PASS Navigator interface: window.navigator must inherit property "appCodeName" with the proper type (0) 
@@ -5646,7 +5644,7 @@ PASS Navigator interface: window.navigator must inherit property "cookieEnabled"
 FAIL Navigator interface: window.navigator must inherit property "yieldForStorageUpdates" with the proper type (17) assert_inherits: property "yieldForStorageUpdates" not found in prototype chain
 PASS Navigator interface: window.navigator must inherit property "plugins" with the proper type (18) 
 PASS Navigator interface: window.navigator must inherit property "mimeTypes" with the proper type (19) 
-FAIL Navigator interface: window.navigator must inherit property "javaEnabled" with the proper type (20) assert_equals: expected "boolean" but got "function"
+PASS Navigator interface: window.navigator must inherit property "javaEnabled" with the proper type (20) 
 PASS PluginArray interface: existence and properties of interface object 
 PASS PluginArray interface object length 
 PASS PluginArray interface object name 
index d0224bc28edd4edb72a162b9cdc936509d2e9f79..15111a30892824879b0bc3c564cff6b5c3a4c2b1 100644 (file)
@@ -2571,7 +2571,7 @@ interface NavigatorStorageUtils {
 interface NavigatorPlugins {
   readonly attribute PluginArray plugins;
   readonly attribute MimeTypeArray mimeTypes;
-  readonly attribute boolean javaEnabled;
+  boolean javaEnabled();
 };
 
 interface PluginArray {
index 2a8af532956144eae4b8e1a378a3c45327a0dd77..c8f388f79a3ac6fa5d81079e33df04541516fa1e 100644 (file)
@@ -1,9 +1,6 @@
 
 
 FAIL iframe-allowfullscreen assert_true: Top level document has fullscreen enabled flag set expected true got undefined
-FAIL iframe-sandbox-allowfullscreen assert_true: Top level document has fullscreen enabled flag set expected true got undefined
-FAIL iframe-allowfullscreen-dialog assert_true: Top level document has fullscreen enabled flag set expected true got undefined
-FAIL iframe-sandbox-allowfullscreen-dialog assert_true: Top level document has fullscreen enabled flag set expected true got undefined
 FAIL iframe-noload-noallowfullscreen assert_false: Fullscreen should not be enabled without allowfullscreen attribute expected false got undefined
 FAIL iframe-noload-allowfullscreen assert_true: Fullscreen should be enabled with allowfullscreen attribute expected true got undefined
 
index 9071a0b89e59f91264d97970e7fee524d52eb799..da5791a2de9b23cbfd7496edc7c3f354756f1e36 100644 (file)
@@ -10,9 +10,8 @@
 
 <div id="log"></div>
 <script>
-  function test_allowfullscreen(t, setup_iframe) {
+  async_test(function(t) {
     var iframe = document.createElement("iframe");
-    setup_iframe(iframe);
     iframe.src = "support/blank.htm";
     var eventWatcher = new EventWatcher(t, iframe, "load");
     document.body.appendChild(iframe);
     });
 
     assert_true(document.fullscreenEnabled, "Top level document has fullscreen enabled flag set");
-    eventWatcher.wait_for("load").then(t.step_func(function() {
+    eventWatcher.wait_for("load").then(t.step_func_done(function() {
       assert_false(iframe.contentDocument.fullscreenEnabled, "Document inside iframe without allowfullscreen attribute should not have fullscreen enabled flag set");
       iframe.setAttribute("allowfullscreen", true);
-      assert_false(iframe.contentDocument.fullscreenEnabled, "Setting allowfullscreen attribute after document load should not affect fullscreen enabled flag");
-      iframe.contentWindow.location.reload();
-      return eventWatcher.wait_for("load");
-    })).then(t.step_func(function() {
-      assert_true(iframe.contentDocument.fullscreenEnabled, "Fullscreen enabled flag should be set when a new document is loaded with allowfullscreen attribute present");
+      assert_true(iframe.contentDocument.fullscreenEnabled, "Fullscreen should be allowed when allowfullscreen attribute is set");
       iframe.removeAttribute("allowfullscreen");
-      assert_true(iframe.contentDocument.fullscreenEnabled, "Removing allowfullscreen attribute should not affect fullscreen enabled flag");
-      iframe.contentWindow.location.reload();
-      return eventWatcher.wait_for("load");
-    })).then(t.step_func_done(function() {
-      assert_false(iframe.contentDocument.fullscreenEnabled, "Fullscreen enabled flag should be reset when a new document is loaded with allowfullscreen attribute absent");
+      assert_false(iframe.contentDocument.fullscreenEnabled, "Fullscreen should be denied when allowfullscreen attribute is removed");
     }));
-  }
-
-  async_test(function(t) {
-    test_allowfullscreen(t, function(iframe) {});
   }, "iframe-allowfullscreen");
 
-  async_test(function(t) {
-    test_allowfullscreen(t, function(iframe) {
-      iframe.setAttribute("sandbox", "allow-same-origin");
-    });
-  }, "iframe-sandbox-allowfullscreen");
-
-  /* Fullscreen enabled flag with dialog */
-
-  function test_allowfullscreen_dialog(t, setup_iframe, check) {
-    var iframe = document.createElement("iframe");
-    setup_iframe(iframe);
-    iframe.src = "support/blank.htm";
-    var eventWatcher = new EventWatcher(t, iframe, "load");
-    document.body.appendChild(iframe);
-    t.add_cleanup(function() {
-      document.body.removeChild(iframe);
-    });
-
-    var newWin;
-    assert_true(document.fullscreenEnabled, "Top level document has fullscreen enabled flag set");
-    eventWatcher.wait_for("load").then(t.step_func(function() {
-      assert_false(iframe.contentDocument.fullscreenEnabled, "Document inside iframe without allowfullscreen attribute should not have fullscreen enabled flag set");
-      newWin = iframe.contentWindow.open("support/blank.htm");
-      t.add_cleanup(function() {
-        newWin.close();
-      });
-      var newWinEventWatcher = new EventWatcher(t, newWin, "load");
-      return newWinEventWatcher.wait_for("load");
-    })).then(t.step_func_done(function() {
-      check(newWin);
-    }));
-  }
-
-  async_test(function(t) {
-    test_allowfullscreen_dialog(t, function() {}, function(newWin) {
-      assert_true(newWin.document.fullscreenEnabled, "Document in the new window is a top level document, thus should has fullscreen enabled flag set");
-    });
-  }, "iframe-allowfullscreen-dialog");
-
-  async_test(function(t) {
-    test_allowfullscreen_dialog(t, function(iframe) {
-      iframe.setAttribute("sandbox", "allow-same-origin allow-popups");
-    }, function(newWin) {
-      assert_false(newWin.document.fullscreenEnabled, "Document in the new window should inherit the sandboxed fullscreen flag and should not have fullscreen enabled flag set");
-    });
-  }, "iframe-sandbox-allowfullscreen-dialog");
-
   /* Fullscreen enabled flag with about:blank */
 
   function test_allowfullscreen_noload(setup_iframe, check) {
index 7d37d99254671fe8117399734d3e73a308da6ccb..a36f519c4fe84216e77faf0f195766bf2eed4e51 100644 (file)
@@ -4,7 +4,7 @@ Harness Error (TIMEOUT), message = null
 
 PASS img (no src), onload, narrow 
 PASS img (no src), resize to wide 
-FAIL img (empty src), onload, narrow assert_equals: expected "" but got "http://localhost:8800/html/semantics/embedded-content/the-img-element/environment-changes/iframed.sub.html?id=d8d26f64-5aa4-456c-a535-7ac76894546f"
+FAIL img (empty src), onload, narrow assert_equals: expected "" but got "http://localhost:8800/html/semantics/embedded-content/the-img-element/environment-changes/iframed.sub.html?id=d6faadce-3036-450a-9bee-b52b02702197"
 PASS img (empty src), resize to wide 
 PASS img (src only) broken image, onload, narrow 
 PASS img (src only) broken image, resize to wide 
@@ -26,7 +26,7 @@ PASS picture: same URL in source (max-width:500px) and img, onload, narrow
 FAIL picture: same URL in source (max-width:500px) and img, resize to wide assert_unreached: Got unexpected load event Reached unreachable code
 PASS img (no src), onload, wide 
 PASS img (no src), resize to narrow 
-FAIL img (empty src), onload, wide assert_equals: expected "" but got "http://localhost:8800/html/semantics/embedded-content/the-img-element/environment-changes/iframed.sub.html?id=f1cb87a8-4fac-47a8-9808-f8ae48010ebd"
+FAIL img (empty src), onload, wide assert_equals: expected "" but got "http://localhost:8800/html/semantics/embedded-content/the-img-element/environment-changes/iframed.sub.html?id=506be0db-2b43-4f00-a52d-1e4d6e74ac9c"
 PASS img (empty src), resize to narrow 
 PASS img (src only) broken image, onload, wide 
 PASS img (src only) broken image, resize to narrow 
@@ -36,13 +36,13 @@ PASS img (srcset 1 cand) broken image, onload, wide
 PASS img (srcset 1 cand) broken image, resize to narrow 
 PASS img (srcset 1 cand) valid image, onload, wide 
 PASS img (srcset 1 cand) valid image, resize to narrow 
-FAIL picture: source (max-width:500px) broken image, img broken image, onload, wide assert_equals: expected "http://localhost:8800/images/broken.png?71-f1cb87a8-4fac-47a8-9808-f8ae48010ebd" but got "http://localhost:8800/images/broken.png?70-f1cb87a8-4fac-47a8-9808-f8ae48010ebd"
+FAIL picture: source (max-width:500px) broken image, img broken image, onload, wide assert_equals: expected "http://localhost:8800/images/broken.png?71-506be0db-2b43-4f00-a52d-1e4d6e74ac9c" but got "http://localhost:8800/images/broken.png?70-506be0db-2b43-4f00-a52d-1e4d6e74ac9c"
 TIMEOUT picture: source (max-width:500px) broken image, img broken image, resize to narrow Test timed out
-FAIL picture: source (max-width:500px) broken image, img valid image, onload, wide assert_equals: expected "http://localhost:8800/images/green-2x2.png?81-f1cb87a8-4fac-47a8-9808-f8ae48010ebd" but got "http://localhost:8800/images/broken.png?80-f1cb87a8-4fac-47a8-9808-f8ae48010ebd"
+FAIL picture: source (max-width:500px) broken image, img valid image, onload, wide assert_equals: expected "http://localhost:8800/images/green-2x2.png?81-506be0db-2b43-4f00-a52d-1e4d6e74ac9c" but got "http://localhost:8800/images/broken.png?80-506be0db-2b43-4f00-a52d-1e4d6e74ac9c"
 TIMEOUT picture: source (max-width:500px) broken image, img valid image, resize to narrow Test timed out
-FAIL picture: source (max-width:500px) valid image, img broken image, onload, wide assert_equals: expected "http://localhost:8800/images/broken.png?91-f1cb87a8-4fac-47a8-9808-f8ae48010ebd" but got "http://localhost:8800/images/green-1x1.png?90-f1cb87a8-4fac-47a8-9808-f8ae48010ebd"
+FAIL picture: source (max-width:500px) valid image, img broken image, onload, wide assert_equals: expected "http://localhost:8800/images/broken.png?91-506be0db-2b43-4f00-a52d-1e4d6e74ac9c" but got "http://localhost:8800/images/green-1x1.png?90-506be0db-2b43-4f00-a52d-1e4d6e74ac9c"
 TIMEOUT picture: source (max-width:500px) valid image, img broken image, resize to narrow Test timed out
-FAIL picture: source (max-width:500px) valid image, img valid image, onload, wide assert_equals: expected "http://localhost:8800/images/green-2x2.png?101-f1cb87a8-4fac-47a8-9808-f8ae48010ebd" but got "http://localhost:8800/images/green-1x1.png?100-f1cb87a8-4fac-47a8-9808-f8ae48010ebd"
+FAIL picture: source (max-width:500px) valid image, img valid image, onload, wide assert_equals: expected "http://localhost:8800/images/green-2x2.png?101-506be0db-2b43-4f00-a52d-1e4d6e74ac9c" but got "http://localhost:8800/images/green-1x1.png?100-506be0db-2b43-4f00-a52d-1e4d6e74ac9c"
 TIMEOUT picture: source (max-width:500px) valid image, img valid image, resize to narrow Test timed out
 PASS picture: same URL in source (max-width:500px) and img, onload, wide 
 PASS picture: same URL in source (max-width:500px) and img, resize to narrow 
index 86b5453acdaa6f05f45ffa6756c9637821260b7f..aae1cdfeb48cb6834ec2f06f25a57ca0f8b6640b 100644 (file)
@@ -63,8 +63,6 @@ list item
 list item
 list item
 
-PASS The prototype for li is HTMLLIElement.prototype 
-FAIL li should have a 'value' attribute assert_own_property: li should have a 'value' attribute expected property "value" missing
 PASS Default (unspecified) value of value is 0. 
 PASS .value property reflects content attribute - and both parse value of '2' correctly. 
 PASS IDL and content attribute parse value of '-10' correctly. 
index 9deb9b591395e383af68f418e880b19a05e38086..fa342b3e280eeb2adcd072e37cf31a6eb2f36d10 100644 (file)
@@ -37,7 +37,7 @@
 
     <p>Unordered List</p>
     <ul id="unordered">
-        <li id="test_li">list item</li>
+        <li>list item</li>
         <li>list item</li>
         <li>list item</li>
     </ul>
     <script>
         "use strict";
 
-        var testLI = document.getElementById("test_li"), testList = [], i = 0;
-
-        // check that prototype matches spec's DOM interface
-        test(function() {
-            assert_equals(Object.getPrototypeOf(testLI), HTMLLIElement.prototype, "HTMLLIElement.prototype should be used for li");
-        }, "The prototype for li is HTMLLIElement.prototype");
-
-        // check that "own" property "value" is present
-        test(function() {
-            assert_own_property(testLI,"value", "li should have a 'value' attribute");
-        }, "li should have a 'value' attribute");
-
         // "The [value] attribute has no default value" so, per https://html.spec.whatwg.org/multipage/#reflect,
         // the default when unspecified is 0
-        testList = document.querySelectorAll("#unordered li, #basic li");
         test(function() {
-            for(i = 0; i < testList.length; i++) {
+            var testList = document.querySelectorAll("#unordered li, #basic li");
+            for (var i = 0; i < testList.length; i++) {
                 assert_equals(testList[i].value, 0, "Default (unspecified) value of value is 0.");
             }
         }, "Default (unspecified) value of value is 0.");
 
         // start2's first element has value of 2
         test(function() {
-            testLI = document.getElementById("start2").children[0];
+            var testLI = document.getElementById("start2").children[0];
             assert_equals(testLI.value, 2, "value of 2 -> value of 2");
         }, ".value property reflects content attribute - and both parse value of '2' correctly.");
 
         // negative's first element has value of -10
         test(function() {
-            testLI = document.getElementById("negative").children[0];
+            var testLI = document.getElementById("negative").children[0];
             assert_equals(testLI.value, -10, "value of -10 -> value of -10");
         }, "IDL and content attribute parse value of '-10' correctly.");
 
         // posFloatDown's first element has value of 4.03 which should return 4
         test(function() {
-            testLI = document.getElementById("posFloatDown").children[0];
+            var testLI = document.getElementById("posFloatDown").children[0];
             assert_equals(testLI.value, 4, "value of 4.03 -> 4");
         }, "IDL and content attribute parse value of '4.03' correctly.");
 
         // negFloatDown's first element has value of -4.03 which should return -4
         test(function() {
-            testLI = document.getElementById("negFloatDown").children[0];
+            var testLI = document.getElementById("negFloatDown").children[0];
             assert_equals(testLI.value, -4, "value of -4.03 -> -4");
         }, "IDL and content attribute parse value of '-4.03' correctly.");
 
         // posFloatUp's first element has value of 4.9 which should return 4
         test(function() {
-            testLI = document.getElementById("posFloatUp").children[0];
+            var testLI = document.getElementById("posFloatUp").children[0];
             assert_equals(testLI.value, 4, "value of 4.9 -> 4");
         }, "IDL and content attribute parse value of '4.9' correctly.");
 
         // negFloatUp's first element has value of -4.9 which should return -4
         test(function() {
-            testLI = document.getElementById("negFloatUp").children[0];
+            var testLI = document.getElementById("negFloatUp").children[0];
             assert_equals(testLI.value, -4, "value of -4.9 -> -4");
         }, "IDL and content attribute parse value of '-4.9' correctly.");
 
         // exponent's first element has value of 7e2 which should return 7
         test(function() {
-            testLI = document.getElementById("exponent").children[0];
+            var testLI = document.getElementById("exponent").children[0];
             assert_equals(testLI.value, 7, "value of 7e2 -> 7");
         }, "IDL and content attribute parse value of '7e2' correctly.");
 
         // decimal's first element has value of .5 which should return 0
         test(function() {
-            testLI = document.getElementById("decimal").children[0];
+            var testLI = document.getElementById("decimal").children[0];
             assert_equals(testLI.value, 0, "value of .5 -> 0 (default)");
         }, "IDL and content attribute parse value of '.5' correctly.");
 
         // letter's first element has value of A which should return 0
         test(function() {
-            testLI = document.getElementById("letter").children[0];
+            var testLI = document.getElementById("letter").children[0];
             assert_equals(testLI.value, 0, "value of A -> 0 (default)");
         }, "IDL and content attribute parse value of 'A' correctly.");
 
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open-expected.txt
new file mode 100644 (file)
index 0000000..cc50a28
--- /dev/null
@@ -0,0 +1,10 @@
+foobar
+
+OK
+foobar
+
+OK
+
+FAIL On getting, the IDL open attribute must return true if the content open attribute is set, and false if it is absent. assert_false: expected false got undefined
+FAIL On setting, the content open attribute must be removed if the IDL open attribute is set to false, and must be present if the IDL open attribute is set to true. assert_true: expected true got false
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html
new file mode 100644 (file)
index 0000000..4719f63
--- /dev/null
@@ -0,0 +1,30 @@
+<!doctype html>
+<meta charset="utf-8">
+<title>dialog element: open</title>
+<link rel=help href="https://html.spec.whatwg.org/multipage/forms.html#dom-dialog-open">
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<dialog id="d1">
+  <p>foobar</p>
+  <button>OK</button>
+</dialog>
+<dialog id="d2" open>
+  <p>foobar</p>
+  <button>OK</button>
+</dialog>
+<script>
+  var d1 = document.getElementById('d1');
+  var d2 = document.getElementById('d2');
+
+  test(function(){
+    assert_false(d1.open);
+    assert_true(d2.open);
+  }, "On getting, the IDL open attribute must return true if the content open attribute is set, and false if it is absent.");
+
+  test(function(){
+    d1.open = true;
+    assert_true(d1.hasAttribute("open"));
+    d2.open = false;
+    assert_false(d2.hasAttribute("open"));
+  }, "On setting, the content open attribute must be removed if the IDL open attribute is set to false, and must be present if the IDL open attribute is set to true.");
+</script>
index e5c3960daffb84c47665ef1f25c5134e7eea98a2..56a3da142d5e4f55c47b51e7aa2116c47c726ccc 100644 (file)
@@ -17,4 +17,5 @@ None
 List of files:
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/contains.json
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-close.html
+/LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-open.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03-expected.txt
new file mode 100644 (file)
index 0000000..ae9f8fd
--- /dev/null
@@ -0,0 +1,3 @@
+
+PASS Script changing @charset 
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html
new file mode 100644 (file)
index 0000000..4ff4cc6
--- /dev/null
@@ -0,0 +1,20 @@
+<!DOCTYPE html>
+<head>
+<meta charset="utf-8">
+<title>Script changing @charset</title>
+<link rel="help" href="https://html.spec.whatwg.org/multipage/#scriptingLanguages">
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<div id="log"></div>
+<script>
+async_test(function() {
+  var s = document.createElement("script");
+  s.src = "external-script-windows1250.js";
+  s.charset = "windows-1250";
+  document.body.appendChild(s);
+  s.charset = "utf-8";
+  window.onload = this.step_func_done(function() {
+    assert_equals(window.getSomeString(), "\u015b\u0107\u0105\u017c\u017a");
+  });
+})
+</script>
index 98da23cf35f80089864d7d0da2d80d7639064718..73d0012876b204ab3f82ca0d76075ff2de39a5be 100644 (file)
@@ -33,6 +33,7 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-before-after-events.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-01.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-02.html
+/LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-charset-03.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-for-event-xhtml.xhtml
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-for-event.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/script-language-type.html
index ce3fc274268486d1806d4342ba4596bc5d624acd..9e9cd31bf061e6fb352315bbe84935e010d0c5f1 100644 (file)
@@ -7,4 +7,5 @@ PASS createCaption will not create new caption if one exists
 PASS createCaption will not copy table's prefix 
 PASS deleteCaption method removes the first caption element child of the table element 
 PASS deleteCaption method not remove caption that is not in html namespace 
+PASS Setting caption rethrows exception 
 
index 79546eb594637beae956c6eeea554a535d44da44..35ee9f44530338fefc6062b704500cd6172a1d47 100644 (file)
@@ -36,6 +36,8 @@
   </table>
   <table id="table4" style="display:none">
   </table>
+  <table id="table5" style="display:none">
+  </table>
   <script>
     test(function () {
       var table0 = document.getElementById('table0');
       table4.deleteCaption();
       assert_equals(caption.parentNode, table4);
     }, "deleteCaption method not remove caption that is not in html namespace")
+    test(function() {
+      var table5 = document.getElementById('table5');
+      var caption = document.createElement('caption');
+      caption.appendChild(table5)
+
+      // Node cannot be inserted at the specified point in the hierarchy
+      assert_throws("HierarchyRequestError", function() {
+        table5.caption = caption;
+      });
+
+      assert_not_equals(table5.caption, caption);
+    }, "Setting caption rethrows exception");
   </script>
 </body>
 </html>
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row-expected.txt
new file mode 100644 (file)
index 0000000..2cbec46
--- /dev/null
@@ -0,0 +1,7 @@
+First column   Second column
+
+PASS deleteRow function invalid argument 
+PASS deleteRow function invalid argument bis 
+PASS check normal deleteRow 
+PASS check normal deleteRow bis 
+
diff --git a/LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html b/LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html
new file mode 100644 (file)
index 0000000..b0e529f
--- /dev/null
@@ -0,0 +1,50 @@
+<!doctype html>
+<meta charset="utf-8">
+<title>Delete Row tests</title>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+
+<table id="element">
+  <thead>
+    <th>First column</th>
+    <th>Second column</th>
+  </thead>
+  <tbody>
+    <tr>
+      <td>1.1</td>
+      <td>1.2</td>
+    </tr>
+    <tr>
+      <td>2.1</td>
+      <td>2.2</td>
+    </tr>
+  </tbody>
+</table>
+
+<script>
+var el = document.getElementById('element');
+
+test(function() {
+  assert_throws("IndexSizeError", function() {
+    el.deleteRow(-2)
+  })
+}, 'deleteRow function invalid argument');
+test(function() {
+  assert_throws("IndexSizeError", function() {
+    el.deleteRow(el.rows.length)
+  })
+}, 'deleteRow function invalid argument bis');
+
+test(function() {
+  var old_length = el.rows.length;
+  el.insertRow(-1);
+  el.deleteRow(-1);
+  assert_equals(old_length, el.rows.length);
+}, "check normal deleteRow");
+test(function() {
+  while (el.rows.length > 1) {
+    el.deleteRow(-1);
+  }
+  assert_equals(1, el.rows.length);
+}, "check normal deleteRow bis");
+</script>
index 57380366af0f2022b91e522668405cf52b75759e..19408cdb1262a1c6802888080f709d13d539f9a5 100644 (file)
@@ -22,6 +22,7 @@ List of files:
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/insertRow-method-01.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/insertRow-method-02.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/insertRow-method-03.html
+/LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/remove-row.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/tBodies.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/tFoot.html
 /LayoutTests/imported/w3c/web-platform-tests/html/semantics/tabular-data/the-table-element/tHead.html
index f5225bc80025780e1b1e9a13ae140387d687c6f7..231a9cf50bbd25d379bfe4235af1180943c8f5f4 100644 (file)
@@ -26,6 +26,7 @@ INDENT TABS: webaudio/*
 INDENT TABS: webvtt/*
 INDENT TABS: XMLHttpRequest/*
 INDENT TABS: encoding/legacy*/*
+INDENT TABS: encrypted-media/polyfill/Makefile
 
 TRAILING WHITESPACE: app-uri/*
 TRAILING WHITESPACE: battery-status/*
index 87ca221c1a3a0843edc33acab9027c9928fca530..355df07960c42663d99648f19d9e31c384d12c94 100644 (file)
@@ -152,7 +152,7 @@ def main():
         out_dir = os.path.dirname(out_path)
         if not os.path.exists(out_dir):
             os.makedirs(out_dir)
-        with open(os.path.join(test_path, path)) as in_f:
+        with open(os.path.join(test_path, path), "r") as in_f:
             data = []
             sub = False
             for line in in_f:
@@ -189,7 +189,7 @@ def main():
 
     for path in source_paths(work_path):
         full_path = os.path.join(work_path, path)
-        with open(full_path) as f:
+        with open(full_path, "r") as f:
             data = sub_changed_filenames(filename_changes, f)
         with open(full_path, "w") as f:
             f.write(data)