Diff
Modified: trunk/LayoutTests/ChangeLog (206629 => 206630)
--- trunk/LayoutTests/ChangeLog 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/ChangeLog 2016-09-30 05:05:35 UTC (rev 206630)
@@ -1,3 +1,16 @@
+2016-09-29 Chris Dumez <cdu...@apple.com>
+
+ Add support for download attribute on area elements
+ https://bugs.webkit.org/show_bug.cgi?id=162765
+
+ Reviewed by Brent Fulgham.
+
+ Add layout test coverage.
+
+ * http/tests/download/area-download-expected.txt: Added.
+ * http/tests/download/area-download.html: Added.
+ * http/tests/download/resources/FAIL-notify-done.html: Added.
+
2016-09-29 Jiewen Tan <jiewen_...@apple.com>
Expose CryptoKey to web workers
Added: trunk/LayoutTests/http/tests/download/area-download-expected.txt (0 => 206630)
--- trunk/LayoutTests/http/tests/download/area-download-expected.txt (rev 0)
+++ trunk/LayoutTests/http/tests/download/area-download-expected.txt 2016-09-30 05:05:35 UTC (rev 206630)
@@ -0,0 +1,12 @@
+Download started.
+Downloading URL with suggested filename "foo.pdf"
+Download completed.
+
+Tests that the download attribute on area elements is working.
+
+The suggested filename at the top should be foo.pdf.
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Added: trunk/LayoutTests/http/tests/download/area-download.html (0 => 206630)
--- trunk/LayoutTests/http/tests/download/area-download.html (rev 0)
+++ trunk/LayoutTests/http/tests/download/area-download.html 2016-09-30 05:05:35 UTC (rev 206630)
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+<script>
+ if (window.testRunner)
+ testRunner.waitUntilDownloadFinished();
+</script>
+</head>
+<body>
+<img id="testImage" src="" usemap=""
+<map name="testmap">
+ <area shape="rect" coords="0,0,100,100" href="" alt="Test" download="foo.pdf">
+</map>
+<p>Tests that the download attribute on area elements is working.</p>
+<p>The suggested filename at the top should be foo.pdf.</p>
+<div id="console"></div>
+<script>
+ function click(elmt)
+ {
+ if (!window.eventSender)
+ return;
+
+ eventSender.mouseMoveTo(elmt.offsetLeft + 10, elmt.offsetTop + 10);
+ eventSender.mouseDown();
+ eventSender.mouseUp();
+ }
+
+ function runTest()
+ {
+ var img = document.getElementById("testImage");
+ click(img);
+ }
+ _onload_ = function() {
+ runTest();
+ }
+</script>
+<script src=""
+</body>
+</html>
Added: trunk/LayoutTests/http/tests/download/resources/FAIL-notify-done.html (0 => 206630)
--- trunk/LayoutTests/http/tests/download/resources/FAIL-notify-done.html (rev 0)
+++ trunk/LayoutTests/http/tests/download/resources/FAIL-notify-done.html 2016-09-30 05:05:35 UTC (rev 206630)
@@ -0,0 +1,11 @@
+<!DOCTYPE html>
+<body>
+FAIL
+<script>
+_onload_ = function() {
+ if (window.testRunner)
+ testRunner.notifyDone();
+}
+</script>
+</body>
+</html>
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (206629 => 206630)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2016-09-30 05:05:35 UTC (rev 206630)
@@ -1,5 +1,16 @@
2016-09-29 Chris Dumez <cdu...@apple.com>
+ Add support for download attribute on area elements
+ https://bugs.webkit.org/show_bug.cgi?id=162765
+
+ Reviewed by Brent Fulgham.
+
+ Rebaseline W3C test now that more checks are passing.
+
+ * web-platform-tests/html/dom/reflection-embedded-expected.txt:
+
+2016-09-29 Chris Dumez <cdu...@apple.com>
+
Assigning non-numeric to input.minlength should set minlength to 0
https://bugs.webkit.org/show_bug.cgi?id=162727
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt (206629 => 206630)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt 2016-09-30 05:05:35 UTC (rev 206630)
@@ -2270,7 +2270,7 @@
PASS HTMLAreaElement interface: attribute coords
PASS HTMLAreaElement interface: attribute shape
PASS HTMLAreaElement interface: attribute target
-FAIL HTMLAreaElement interface: attribute download assert_true: The prototype object must have a property "download" expected true got false
+PASS HTMLAreaElement interface: attribute download
PASS HTMLAreaElement interface: attribute ping
PASS HTMLAreaElement interface: attribute rel
PASS HTMLAreaElement interface: attribute relList
@@ -2293,7 +2293,7 @@
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "coords" with the proper type (1)
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "shape" with the proper type (2)
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "target" with the proper type (3)
-FAIL HTMLAreaElement interface: document.createElement("area") must inherit property "download" with the proper type (4) assert_inherits: property "download" not found in prototype chain
+PASS HTMLAreaElement interface: document.createElement("area") must inherit property "download" with the proper type (4)
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "ping" with the proper type (5)
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "rel" with the proper type (6)
PASS HTMLAreaElement interface: document.createElement("area") must inherit property "relList" with the proper type (7)
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt (206629 => 206630)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-09-30 05:05:35 UTC (rev 206630)
@@ -14672,83 +14672,83 @@
PASS area.target: IDL set to object "test-valueOf" should not throw
PASS area.target: IDL set to object "test-valueOf" followed by getAttribute()
PASS area.target: IDL set to object "test-valueOf" followed by IDL get
-FAIL area.download: typeof IDL attribute assert_equals: expected "string" but got "undefined"
-FAIL area.download: IDL get with DOM attribute unset assert_equals: expected (string) "" but got (undefined) undefined
+PASS area.download: typeof IDL attribute
+PASS area.download: IDL get with DOM attribute unset
PASS area.download: setAttribute() to "" followed by getAttribute()
-FAIL area.download: setAttribute() to "" followed by IDL get assert_equals: expected (string) "" but got (undefined) undefined
+PASS area.download: setAttribute() to "" followed by IDL get
PASS area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute()
-FAIL area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get assert_equals: expected (string) " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " but got (undefined) undefined
+PASS area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get
PASS area.download: setAttribute() to undefined followed by getAttribute()
-FAIL area.download: setAttribute() to undefined followed by IDL get assert_equals: expected (string) "undefined" but got (undefined) undefined
+PASS area.download: setAttribute() to undefined followed by IDL get
PASS area.download: setAttribute() to 7 followed by getAttribute()
-FAIL area.download: setAttribute() to 7 followed by IDL get assert_equals: expected (string) "7" but got (undefined) undefined
+PASS area.download: setAttribute() to 7 followed by IDL get
PASS area.download: setAttribute() to 1.5 followed by getAttribute()
-FAIL area.download: setAttribute() to 1.5 followed by IDL get assert_equals: expected (string) "1.5" but got (undefined) undefined
+PASS area.download: setAttribute() to 1.5 followed by IDL get
PASS area.download: setAttribute() to true followed by getAttribute()
-FAIL area.download: setAttribute() to true followed by IDL get assert_equals: expected (string) "true" but got (undefined) undefined
+PASS area.download: setAttribute() to true followed by IDL get
PASS area.download: setAttribute() to false followed by getAttribute()
-FAIL area.download: setAttribute() to false followed by IDL get assert_equals: expected (string) "false" but got (undefined) undefined
+PASS area.download: setAttribute() to false followed by IDL get
PASS area.download: setAttribute() to object "[object Object]" followed by getAttribute()
-FAIL area.download: setAttribute() to object "[object Object]" followed by IDL get assert_equals: expected (string) "[object Object]" but got (undefined) undefined
+PASS area.download: setAttribute() to object "[object Object]" followed by IDL get
PASS area.download: setAttribute() to NaN followed by getAttribute()
-FAIL area.download: setAttribute() to NaN followed by IDL get assert_equals: expected (string) "NaN" but got (undefined) undefined
+PASS area.download: setAttribute() to NaN followed by IDL get
PASS area.download: setAttribute() to Infinity followed by getAttribute()
-FAIL area.download: setAttribute() to Infinity followed by IDL get assert_equals: expected (string) "Infinity" but got (undefined) undefined
+PASS area.download: setAttribute() to Infinity followed by IDL get
PASS area.download: setAttribute() to -Infinity followed by getAttribute()
-FAIL area.download: setAttribute() to -Infinity followed by IDL get assert_equals: expected (string) "-Infinity" but got (undefined) undefined
+PASS area.download: setAttribute() to -Infinity followed by IDL get
PASS area.download: setAttribute() to "\0" followed by getAttribute()
-FAIL area.download: setAttribute() to "\0" followed by IDL get assert_equals: expected (string) "\0" but got (undefined) undefined
+PASS area.download: setAttribute() to "\0" followed by IDL get
PASS area.download: setAttribute() to null followed by getAttribute()
-FAIL area.download: setAttribute() to null followed by IDL get assert_equals: expected (string) "null" but got (undefined) undefined
+PASS area.download: setAttribute() to null followed by IDL get
PASS area.download: setAttribute() to object "test-toString" followed by getAttribute()
-FAIL area.download: setAttribute() to object "test-toString" followed by IDL get assert_equals: expected (string) "test-toString" but got (undefined) undefined
+PASS area.download: setAttribute() to object "test-toString" followed by IDL get
PASS area.download: setAttribute() to object "test-valueOf" followed by getAttribute()
-FAIL area.download: setAttribute() to object "test-valueOf" followed by IDL get assert_equals: expected (string) "test-valueOf" but got (undefined) undefined
+PASS area.download: setAttribute() to object "test-valueOf" followed by IDL get
PASS area.download: IDL set to "" should not throw
-FAIL area.download: IDL set to "" followed by getAttribute() assert_equals: expected "" but got "test-valueOf"
+PASS area.download: IDL set to "" followed by getAttribute()
PASS area.download: IDL set to "" followed by IDL get
PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " should not throw
-FAIL area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute() assert_equals: expected " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " but got "test-valueOf"
+PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute()
PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get
PASS area.download: IDL set to undefined should not throw
-FAIL area.download: IDL set to undefined followed by getAttribute() assert_equals: expected "undefined" but got "test-valueOf"
-FAIL area.download: IDL set to undefined followed by IDL get assert_equals: expected (string) "undefined" but got (undefined) undefined
+PASS area.download: IDL set to undefined followed by getAttribute()
+PASS area.download: IDL set to undefined followed by IDL get
PASS area.download: IDL set to 7 should not throw
-FAIL area.download: IDL set to 7 followed by getAttribute() assert_equals: expected "7" but got "test-valueOf"
-FAIL area.download: IDL set to 7 followed by IDL get assert_equals: expected (string) "7" but got (number) 7
+PASS area.download: IDL set to 7 followed by getAttribute()
+PASS area.download: IDL set to 7 followed by IDL get
PASS area.download: IDL set to 1.5 should not throw
-FAIL area.download: IDL set to 1.5 followed by getAttribute() assert_equals: expected "1.5" but got "test-valueOf"
-FAIL area.download: IDL set to 1.5 followed by IDL get assert_equals: expected (string) "1.5" but got (number) 1.5
+PASS area.download: IDL set to 1.5 followed by getAttribute()
+PASS area.download: IDL set to 1.5 followed by IDL get
PASS area.download: IDL set to true should not throw
-FAIL area.download: IDL set to true followed by getAttribute() assert_equals: expected "true" but got "test-valueOf"
-FAIL area.download: IDL set to true followed by IDL get assert_equals: expected (string) "true" but got (boolean) true
+PASS area.download: IDL set to true followed by getAttribute()
+PASS area.download: IDL set to true followed by IDL get
PASS area.download: IDL set to false should not throw
-FAIL area.download: IDL set to false followed by getAttribute() assert_equals: expected "false" but got "test-valueOf"
-FAIL area.download: IDL set to false followed by IDL get assert_equals: expected (string) "false" but got (boolean) false
+PASS area.download: IDL set to false followed by getAttribute()
+PASS area.download: IDL set to false followed by IDL get
PASS area.download: IDL set to object "[object Object]" should not throw
-FAIL area.download: IDL set to object "[object Object]" followed by getAttribute() assert_equals: expected "[object Object]" but got "test-valueOf"
-FAIL area.download: IDL set to object "[object Object]" followed by IDL get assert_equals: expected (string) "[object Object]" but got (object) object "[object Object]"
+PASS area.download: IDL set to object "[object Object]" followed by getAttribute()
+PASS area.download: IDL set to object "[object Object]" followed by IDL get
PASS area.download: IDL set to NaN should not throw
-FAIL area.download: IDL set to NaN followed by getAttribute() assert_equals: expected "NaN" but got "test-valueOf"
-FAIL area.download: IDL set to NaN followed by IDL get assert_equals: expected (string) "NaN" but got (number) NaN
+PASS area.download: IDL set to NaN followed by getAttribute()
+PASS area.download: IDL set to NaN followed by IDL get
PASS area.download: IDL set to Infinity should not throw
-FAIL area.download: IDL set to Infinity followed by getAttribute() assert_equals: expected "Infinity" but got "test-valueOf"
-FAIL area.download: IDL set to Infinity followed by IDL get assert_equals: expected (string) "Infinity" but got (number) Infinity
+PASS area.download: IDL set to Infinity followed by getAttribute()
+PASS area.download: IDL set to Infinity followed by IDL get
PASS area.download: IDL set to -Infinity should not throw
-FAIL area.download: IDL set to -Infinity followed by getAttribute() assert_equals: expected "-Infinity" but got "test-valueOf"
-FAIL area.download: IDL set to -Infinity followed by IDL get assert_equals: expected (string) "-Infinity" but got (number) -Infinity
+PASS area.download: IDL set to -Infinity followed by getAttribute()
+PASS area.download: IDL set to -Infinity followed by IDL get
PASS area.download: IDL set to "\0" should not throw
-FAIL area.download: IDL set to "\0" followed by getAttribute() assert_equals: expected "\0" but got "test-valueOf"
+PASS area.download: IDL set to "\0" followed by getAttribute()
PASS area.download: IDL set to "\0" followed by IDL get
PASS area.download: IDL set to null should not throw
-FAIL area.download: IDL set to null followed by getAttribute() assert_equals: expected "null" but got "test-valueOf"
-FAIL area.download: IDL set to null followed by IDL get assert_equals: expected (string) "null" but got (object) null
+PASS area.download: IDL set to null followed by getAttribute()
+PASS area.download: IDL set to null followed by IDL get
PASS area.download: IDL set to object "test-toString" should not throw
-FAIL area.download: IDL set to object "test-toString" followed by getAttribute() assert_equals: expected "test-toString" but got "test-valueOf"
-FAIL area.download: IDL set to object "test-toString" followed by IDL get assert_equals: expected (string) "test-toString" but got (object) object "test-toString"
+PASS area.download: IDL set to object "test-toString" followed by getAttribute()
+PASS area.download: IDL set to object "test-toString" followed by IDL get
PASS area.download: IDL set to object "test-valueOf" should not throw
PASS area.download: IDL set to object "test-valueOf" followed by getAttribute()
-FAIL area.download: IDL set to object "test-valueOf" followed by IDL get assert_equals: expected (string) "test-valueOf" but got (object) object "test-valueOf"
+PASS area.download: IDL set to object "test-valueOf" followed by IDL get
PASS area.ping: typeof IDL attribute
PASS area.ping: IDL get with DOM attribute unset
PASS area.ping: setAttribute() to "" followed by getAttribute()
Modified: trunk/LayoutTests/platform/ios-simulator-wk1/TestExpectations (206629 => 206630)
--- trunk/LayoutTests/platform/ios-simulator-wk1/TestExpectations 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/platform/ios-simulator-wk1/TestExpectations 2016-09-30 05:05:35 UTC (rev 206630)
@@ -1314,6 +1314,7 @@
# <a download> is not supported in WK1 yet.
webkit.org/b/156069 fast/dom/HTMLAnchorElement/anchor-download-synthetic-click.html [ Skip ]
+webkit.org/b/156069 http/tests/download/area-download.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-blob.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-data.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-sameorigin.html [ Skip ]
Modified: trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations (206629 => 206630)
--- trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations 2016-09-30 05:05:35 UTC (rev 206630)
@@ -741,10 +741,6 @@
fast/dom/Geolocation/permission-denied-already-error.html
fast/dom/Geolocation/permission-denied-stops-watches.html
fast/dom/Geolocation/requestQueuingForHiddenPage.html
-fast/dom/HTMLAnchorElement/anchor-download-unset.html
-fast/dom/HTMLAnchorElement/anchor-download.html
-fast/dom/HTMLAnchorElement/anchor-nodownload-set.html
-fast/dom/HTMLAnchorElement/anchor-nodownload.html
fast/dom/HTMLLinkElement/prefetch.html
fast/dom/MutationObserver/end-of-task-delivery.html
fast/dom/Node/mutation-blur.html
@@ -1806,7 +1802,12 @@
webkit.org/b/155948 transitions/cancel-transition.html [ Pass Failure ]
-# <a download> is not supported with NETWORK_SESSION yet.
+# <a download> does not work on iOS.
+webkit.org/b/156067 fast/dom/HTMLAnchorElement/anchor-download-unset.html [ Skip ]
+webkit.org/b/156067 fast/dom/HTMLAnchorElement/anchor-download.html [ Skip ]
+webkit.org/b/156067 fast/dom/HTMLAnchorElement/anchor-nodownload-set.html [ Skip ]
+webkit.org/b/156067 fast/dom/HTMLAnchorElement/anchor-nodownload.html [ Skip ]
+webkit.org/b/156067 http/tests/download/area-download.html [ Skip ]
webkit.org/b/156067 http/tests/security/anchor-download-allow-blob.html [ Skip ]
webkit.org/b/156067 http/tests/security/anchor-download-allow-data.html [ Skip ]
webkit.org/b/156067 http/tests/security/anchor-download-allow-sameorigin.html [ Skip ]
Modified: trunk/LayoutTests/platform/ios-simulator-wk2/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt (206629 => 206630)
--- trunk/LayoutTests/platform/ios-simulator-wk2/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/platform/ios-simulator-wk2/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-09-30 05:05:35 UTC (rev 206630)
@@ -14672,83 +14672,83 @@
PASS area.target: IDL set to object "test-valueOf" should not throw
PASS area.target: IDL set to object "test-valueOf" followed by getAttribute()
PASS area.target: IDL set to object "test-valueOf" followed by IDL get
-FAIL area.download: typeof IDL attribute assert_equals: expected "string" but got "undefined"
-FAIL area.download: IDL get with DOM attribute unset assert_equals: expected (string) "" but got (undefined) undefined
+PASS area.download: typeof IDL attribute
+PASS area.download: IDL get with DOM attribute unset
PASS area.download: setAttribute() to "" followed by getAttribute()
-FAIL area.download: setAttribute() to "" followed by IDL get assert_equals: expected (string) "" but got (undefined) undefined
+PASS area.download: setAttribute() to "" followed by IDL get
PASS area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute()
-FAIL area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get assert_equals: expected (string) " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " but got (undefined) undefined
+PASS area.download: setAttribute() to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get
PASS area.download: setAttribute() to undefined followed by getAttribute()
-FAIL area.download: setAttribute() to undefined followed by IDL get assert_equals: expected (string) "undefined" but got (undefined) undefined
+PASS area.download: setAttribute() to undefined followed by IDL get
PASS area.download: setAttribute() to 7 followed by getAttribute()
-FAIL area.download: setAttribute() to 7 followed by IDL get assert_equals: expected (string) "7" but got (undefined) undefined
+PASS area.download: setAttribute() to 7 followed by IDL get
PASS area.download: setAttribute() to 1.5 followed by getAttribute()
-FAIL area.download: setAttribute() to 1.5 followed by IDL get assert_equals: expected (string) "1.5" but got (undefined) undefined
+PASS area.download: setAttribute() to 1.5 followed by IDL get
PASS area.download: setAttribute() to true followed by getAttribute()
-FAIL area.download: setAttribute() to true followed by IDL get assert_equals: expected (string) "true" but got (undefined) undefined
+PASS area.download: setAttribute() to true followed by IDL get
PASS area.download: setAttribute() to false followed by getAttribute()
-FAIL area.download: setAttribute() to false followed by IDL get assert_equals: expected (string) "false" but got (undefined) undefined
+PASS area.download: setAttribute() to false followed by IDL get
PASS area.download: setAttribute() to object "[object Object]" followed by getAttribute()
-FAIL area.download: setAttribute() to object "[object Object]" followed by IDL get assert_equals: expected (string) "[object Object]" but got (undefined) undefined
+PASS area.download: setAttribute() to object "[object Object]" followed by IDL get
PASS area.download: setAttribute() to NaN followed by getAttribute()
-FAIL area.download: setAttribute() to NaN followed by IDL get assert_equals: expected (string) "NaN" but got (undefined) undefined
+PASS area.download: setAttribute() to NaN followed by IDL get
PASS area.download: setAttribute() to Infinity followed by getAttribute()
-FAIL area.download: setAttribute() to Infinity followed by IDL get assert_equals: expected (string) "Infinity" but got (undefined) undefined
+PASS area.download: setAttribute() to Infinity followed by IDL get
PASS area.download: setAttribute() to -Infinity followed by getAttribute()
-FAIL area.download: setAttribute() to -Infinity followed by IDL get assert_equals: expected (string) "-Infinity" but got (undefined) undefined
+PASS area.download: setAttribute() to -Infinity followed by IDL get
PASS area.download: setAttribute() to "\0" followed by getAttribute()
-FAIL area.download: setAttribute() to "\0" followed by IDL get assert_equals: expected (string) "\0" but got (undefined) undefined
+PASS area.download: setAttribute() to "\0" followed by IDL get
PASS area.download: setAttribute() to null followed by getAttribute()
-FAIL area.download: setAttribute() to null followed by IDL get assert_equals: expected (string) "null" but got (undefined) undefined
+PASS area.download: setAttribute() to null followed by IDL get
PASS area.download: setAttribute() to object "test-toString" followed by getAttribute()
-FAIL area.download: setAttribute() to object "test-toString" followed by IDL get assert_equals: expected (string) "test-toString" but got (undefined) undefined
+PASS area.download: setAttribute() to object "test-toString" followed by IDL get
PASS area.download: setAttribute() to object "test-valueOf" followed by getAttribute()
-FAIL area.download: setAttribute() to object "test-valueOf" followed by IDL get assert_equals: expected (string) "test-valueOf" but got (undefined) undefined
+PASS area.download: setAttribute() to object "test-valueOf" followed by IDL get
PASS area.download: IDL set to "" should not throw
-FAIL area.download: IDL set to "" followed by getAttribute() assert_equals: expected "" but got "test-valueOf"
+PASS area.download: IDL set to "" followed by getAttribute()
PASS area.download: IDL set to "" followed by IDL get
PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " should not throw
-FAIL area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute() assert_equals: expected " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " but got "test-valueOf"
+PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by getAttribute()
PASS area.download: IDL set to " \0\x01\x02\x03\x04\x05\x06\x07 \b\t\n\v\f\r\x0e\x0f \x10\x11\x12\x13\x14\x15\x16\x17 \x18\x19\x1a\x1b\x1c\x1d\x1e\x1f foo " followed by IDL get
PASS area.download: IDL set to undefined should not throw
-FAIL area.download: IDL set to undefined followed by getAttribute() assert_equals: expected "undefined" but got "test-valueOf"
-FAIL area.download: IDL set to undefined followed by IDL get assert_equals: expected (string) "undefined" but got (undefined) undefined
+PASS area.download: IDL set to undefined followed by getAttribute()
+PASS area.download: IDL set to undefined followed by IDL get
PASS area.download: IDL set to 7 should not throw
-FAIL area.download: IDL set to 7 followed by getAttribute() assert_equals: expected "7" but got "test-valueOf"
-FAIL area.download: IDL set to 7 followed by IDL get assert_equals: expected (string) "7" but got (number) 7
+PASS area.download: IDL set to 7 followed by getAttribute()
+PASS area.download: IDL set to 7 followed by IDL get
PASS area.download: IDL set to 1.5 should not throw
-FAIL area.download: IDL set to 1.5 followed by getAttribute() assert_equals: expected "1.5" but got "test-valueOf"
-FAIL area.download: IDL set to 1.5 followed by IDL get assert_equals: expected (string) "1.5" but got (number) 1.5
+PASS area.download: IDL set to 1.5 followed by getAttribute()
+PASS area.download: IDL set to 1.5 followed by IDL get
PASS area.download: IDL set to true should not throw
-FAIL area.download: IDL set to true followed by getAttribute() assert_equals: expected "true" but got "test-valueOf"
-FAIL area.download: IDL set to true followed by IDL get assert_equals: expected (string) "true" but got (boolean) true
+PASS area.download: IDL set to true followed by getAttribute()
+PASS area.download: IDL set to true followed by IDL get
PASS area.download: IDL set to false should not throw
-FAIL area.download: IDL set to false followed by getAttribute() assert_equals: expected "false" but got "test-valueOf"
-FAIL area.download: IDL set to false followed by IDL get assert_equals: expected (string) "false" but got (boolean) false
+PASS area.download: IDL set to false followed by getAttribute()
+PASS area.download: IDL set to false followed by IDL get
PASS area.download: IDL set to object "[object Object]" should not throw
-FAIL area.download: IDL set to object "[object Object]" followed by getAttribute() assert_equals: expected "[object Object]" but got "test-valueOf"
-FAIL area.download: IDL set to object "[object Object]" followed by IDL get assert_equals: expected (string) "[object Object]" but got (object) object "[object Object]"
+PASS area.download: IDL set to object "[object Object]" followed by getAttribute()
+PASS area.download: IDL set to object "[object Object]" followed by IDL get
PASS area.download: IDL set to NaN should not throw
-FAIL area.download: IDL set to NaN followed by getAttribute() assert_equals: expected "NaN" but got "test-valueOf"
-FAIL area.download: IDL set to NaN followed by IDL get assert_equals: expected (string) "NaN" but got (number) NaN
+PASS area.download: IDL set to NaN followed by getAttribute()
+PASS area.download: IDL set to NaN followed by IDL get
PASS area.download: IDL set to Infinity should not throw
-FAIL area.download: IDL set to Infinity followed by getAttribute() assert_equals: expected "Infinity" but got "test-valueOf"
-FAIL area.download: IDL set to Infinity followed by IDL get assert_equals: expected (string) "Infinity" but got (number) Infinity
+PASS area.download: IDL set to Infinity followed by getAttribute()
+PASS area.download: IDL set to Infinity followed by IDL get
PASS area.download: IDL set to -Infinity should not throw
-FAIL area.download: IDL set to -Infinity followed by getAttribute() assert_equals: expected "-Infinity" but got "test-valueOf"
-FAIL area.download: IDL set to -Infinity followed by IDL get assert_equals: expected (string) "-Infinity" but got (number) -Infinity
+PASS area.download: IDL set to -Infinity followed by getAttribute()
+PASS area.download: IDL set to -Infinity followed by IDL get
PASS area.download: IDL set to "\0" should not throw
-FAIL area.download: IDL set to "\0" followed by getAttribute() assert_equals: expected "\0" but got "test-valueOf"
+PASS area.download: IDL set to "\0" followed by getAttribute()
PASS area.download: IDL set to "\0" followed by IDL get
PASS area.download: IDL set to null should not throw
-FAIL area.download: IDL set to null followed by getAttribute() assert_equals: expected "null" but got "test-valueOf"
-FAIL area.download: IDL set to null followed by IDL get assert_equals: expected (string) "null" but got (object) null
+PASS area.download: IDL set to null followed by getAttribute()
+PASS area.download: IDL set to null followed by IDL get
PASS area.download: IDL set to object "test-toString" should not throw
-FAIL area.download: IDL set to object "test-toString" followed by getAttribute() assert_equals: expected "test-toString" but got "test-valueOf"
-FAIL area.download: IDL set to object "test-toString" followed by IDL get assert_equals: expected (string) "test-toString" but got (object) object "test-toString"
+PASS area.download: IDL set to object "test-toString" followed by getAttribute()
+PASS area.download: IDL set to object "test-toString" followed by IDL get
PASS area.download: IDL set to object "test-valueOf" should not throw
PASS area.download: IDL set to object "test-valueOf" followed by getAttribute()
-FAIL area.download: IDL set to object "test-valueOf" followed by IDL get assert_equals: expected (string) "test-valueOf" but got (object) object "test-valueOf"
+PASS area.download: IDL set to object "test-valueOf" followed by IDL get
PASS area.ping: typeof IDL attribute
PASS area.ping: IDL get with DOM attribute unset
PASS area.ping: setAttribute() to "" followed by getAttribute()
Modified: trunk/LayoutTests/platform/mac-wk1/TestExpectations (206629 => 206630)
--- trunk/LayoutTests/platform/mac-wk1/TestExpectations 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/platform/mac-wk1/TestExpectations 2016-09-30 05:05:35 UTC (rev 206630)
@@ -191,6 +191,7 @@
webkit.org/b/156069 fast/dom/HTMLAnchorElement/anchor-nodownload-set.html [ Failure ]
webkit.org/b/156069 fast/dom/HTMLAnchorElement/anchor-download.html [ Failure ]
webkit.org/b/156069 fast/dom/HTMLAnchorElement/anchor-download-synthetic-click.html [ Skip ]
+webkit.org/b/156069 http/tests/download/area-download.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-blob.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-data.html [ Skip ]
webkit.org/b/156069 http/tests/security/anchor-download-allow-sameorigin.html [ Skip ]
Modified: trunk/LayoutTests/platform/win/TestExpectations (206629 => 206630)
--- trunk/LayoutTests/platform/win/TestExpectations 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/LayoutTests/platform/win/TestExpectations 2016-09-30 05:05:35 UTC (rev 206630)
@@ -442,6 +442,9 @@
fast/dom/HTMLAnchorElement/anchor-download.html [ Skip ]
fast/dom/HTMLAnchorElement/anchor-nodownload-set.html [ Skip ]
fast/dom/HTMLAnchorElement/anchor-download-unset.html [ Skip ]
+http/tests/download/area-download.html [ Skip ]
+http/tests/security/anchor-download-allow-data.html [ Skip ]
+http/tests/security/anchor-download-allow-sameorigin.html [ Skip ]
# TODO Expose title direction in WebKit API (Chromium Only)
webkit.org/b/58845 fast/dom/title-directionality.html [ Skip ]
@@ -3444,8 +3447,6 @@
http/tests/loading/multiple-prioritization.html [ Failure ]
http/tests/misc/favicon-loads-with-icon-loading-override.html [ Failure ]
http/tests/navigation/post-308-response.html [ Failure ]
-http/tests/security/anchor-download-allow-data.html [ Failure ]
-http/tests/security/anchor-download-allow-sameorigin.html [ Failure ]
http/tests/security/canvas-remote-read-remote-video-redirect.html [ Failure ]
http/tests/security/contentSecurityPolicy/1.1/plugintypes-affects-child.html [ Failure ]
http/tests/security/contentSecurityPolicy/1.1/plugintypes-invalid.html [ Failure ]
Modified: trunk/Source/WebCore/ChangeLog (206629 => 206630)
--- trunk/Source/WebCore/ChangeLog 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/Source/WebCore/ChangeLog 2016-09-30 05:05:35 UTC (rev 206630)
@@ -1,3 +1,22 @@
+2016-09-29 Chris Dumez <cdu...@apple.com>
+
+ Add support for download attribute on area elements
+ https://bugs.webkit.org/show_bug.cgi?id=162765
+
+ Reviewed by Brent Fulgham.
+
+ Add support for download attribute on area elements:
+ - https://html.spec.whatwg.org/#htmlanchorelement
+
+ Because HTMLAreaElement inherits from HTMLAnchorElement on native side,
+ and because HTMLAnchorElement already supports the download attribute,
+ all that was needed was to add the download attribute to
+ HTMLAreaElement.idl file.
+
+ Test: http/tests/download/area-download.html
+
+ * html/HTMLAreaElement.idl:
+
2016-09-29 Ryosuke Niwa <rn...@webkit.org>
Editor::findStringAndScrollToVisible is unused
Modified: trunk/Source/WebCore/html/HTMLAreaElement.idl (206629 => 206630)
--- trunk/Source/WebCore/html/HTMLAreaElement.idl 2016-09-30 02:04:07 UTC (rev 206629)
+++ trunk/Source/WebCore/html/HTMLAreaElement.idl 2016-09-30 05:05:35 UTC (rev 206630)
@@ -27,6 +27,8 @@
[Reflect] attribute DOMString shape;
[Reflect] attribute DOMString target;
+ [Conditional=DOWNLOAD_ATTRIBUTE, EnabledAtRuntime=DownloadAttribute, Reflect] attribute DOMString download;
+
[PutForwards=value] readonly attribute DOMTokenList relList;
};