Diff
Modified: trunk/LayoutTests/ChangeLog (203523 => 203524)
--- trunk/LayoutTests/ChangeLog 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/ChangeLog 2016-07-21 21:10:35 UTC (rev 203524)
@@ -1,5 +1,17 @@
2016-07-21 Chris Dumez <[email protected]>
+ Fix null handling for HTMLIFrameElement.marginWidth / marginHeight
+ https://bugs.webkit.org/show_bug.cgi?id=160037
+
+ Reviewed by Ryosuke Niwa.
+
+ Update existing test to reflect the behavior change.
+
+ * fast/dom/element-attribute-js-null-expected.txt:
+ * fast/dom/element-attribute-js-null.html:
+
+2016-07-21 Chris Dumez <[email protected]>
+
Fix null handling for HTMLImageElement.border
https://bugs.webkit.org/show_bug.cgi?id=160039
Modified: trunk/LayoutTests/fast/dom/element-attribute-js-null-expected.txt (203523 => 203524)
--- trunk/LayoutTests/fast/dom/element-attribute-js-null-expected.txt 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/fast/dom/element-attribute-js-null-expected.txt 2016-07-21 21:10:35 UTC (rev 203524)
@@ -97,8 +97,8 @@
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.align]
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.frameBorder]
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.height]
-TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.marginHeight]
-TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.marginWidth]
+TEST SUCCEEDED: The value was the empty string. [tested HTMLIFrameElement.marginHeight]
+TEST SUCCEEDED: The value was the empty string. [tested HTMLIFrameElement.marginWidth]
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.name]
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.scrolling]
TEST SUCCEEDED: The value was the string 'null'. [tested HTMLIFrameElement.width]
Modified: trunk/LayoutTests/fast/dom/element-attribute-js-null.html (203523 => 203524)
--- trunk/LayoutTests/fast/dom/element-attribute-js-null.html 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/fast/dom/element-attribute-js-null.html 2016-07-21 21:10:35 UTC (rev 203524)
@@ -279,8 +279,8 @@
{name: 'align', expectedNull: 'null'},
{name: 'frameBorder', expectedNull: 'null'},
{name: 'height', expectedNull: 'null'},
- {name: 'marginHeight', expectedNull: 'null'},
- {name: 'marginWidth', expectedNull: 'null'},
+ {name: 'marginHeight', expectedNull: ''},
+ {name: 'marginWidth', expectedNull: ''},
{name: 'name', expectedNull: 'null'},
{name: 'scrolling', expectedNull: 'null'},
{name: 'width', expectedNull: 'null'}
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (203523 => 203524)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2016-07-21 21:10:35 UTC (rev 203524)
@@ -1,5 +1,16 @@
2016-07-21 Chris Dumez <[email protected]>
+ Fix null handling for HTMLIFrameElement.marginWidth / marginHeight
+ https://bugs.webkit.org/show_bug.cgi?id=160037
+
+ Reviewed by Ryosuke Niwa.
+
+ Rebaseline W3C test now that more checks are passing.
+
+ * web-platform-tests/html/dom/reflection-embedded-expected.txt:
+
+2016-07-21 Chris Dumez <[email protected]>
+
Fix null handling for HTMLImageElement.border
https://bugs.webkit.org/show_bug.cgi?id=160039
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt (203523 => 203524)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-07-21 21:10:35 UTC (rev 203524)
@@ -3391,8 +3391,8 @@
PASS iframe.marginHeight: IDL set to "\0" followed by getAttribute()
PASS iframe.marginHeight: IDL set to "\0" followed by IDL get
PASS iframe.marginHeight: IDL set to null should not throw
-FAIL iframe.marginHeight: IDL set to null followed by getAttribute() assert_equals: expected "" but got "null"
-FAIL iframe.marginHeight: IDL set to null followed by IDL get assert_equals: expected "" but got "null"
+PASS iframe.marginHeight: IDL set to null followed by getAttribute()
+PASS iframe.marginHeight: IDL set to null followed by IDL get
PASS iframe.marginHeight: IDL set to object "test-toString" should not throw
PASS iframe.marginHeight: IDL set to object "test-toString" followed by getAttribute()
PASS iframe.marginHeight: IDL set to object "test-toString" followed by IDL get
@@ -3468,8 +3468,8 @@
PASS iframe.marginWidth: IDL set to "\0" followed by getAttribute()
PASS iframe.marginWidth: IDL set to "\0" followed by IDL get
PASS iframe.marginWidth: IDL set to null should not throw
-FAIL iframe.marginWidth: IDL set to null followed by getAttribute() assert_equals: expected "" but got "null"
-FAIL iframe.marginWidth: IDL set to null followed by IDL get assert_equals: expected "" but got "null"
+PASS iframe.marginWidth: IDL set to null followed by getAttribute()
+PASS iframe.marginWidth: IDL set to null followed by IDL get
PASS iframe.marginWidth: IDL set to object "test-toString" should not throw
PASS iframe.marginWidth: IDL set to object "test-toString" followed by getAttribute()
PASS iframe.marginWidth: IDL set to object "test-toString" followed by IDL get
Modified: trunk/LayoutTests/platform/ios-simulator/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt (203523 => 203524)
--- trunk/LayoutTests/platform/ios-simulator/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/LayoutTests/platform/ios-simulator/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt 2016-07-21 21:10:35 UTC (rev 203524)
@@ -3391,8 +3391,8 @@
PASS iframe.marginHeight: IDL set to "\0" followed by getAttribute()
PASS iframe.marginHeight: IDL set to "\0" followed by IDL get
PASS iframe.marginHeight: IDL set to null should not throw
-FAIL iframe.marginHeight: IDL set to null followed by getAttribute() assert_equals: expected "" but got "null"
-FAIL iframe.marginHeight: IDL set to null followed by IDL get assert_equals: expected "" but got "null"
+PASS iframe.marginHeight: IDL set to null followed by getAttribute()
+PASS iframe.marginHeight: IDL set to null followed by IDL get
PASS iframe.marginHeight: IDL set to object "test-toString" should not throw
PASS iframe.marginHeight: IDL set to object "test-toString" followed by getAttribute()
PASS iframe.marginHeight: IDL set to object "test-toString" followed by IDL get
@@ -3468,8 +3468,8 @@
PASS iframe.marginWidth: IDL set to "\0" followed by getAttribute()
PASS iframe.marginWidth: IDL set to "\0" followed by IDL get
PASS iframe.marginWidth: IDL set to null should not throw
-FAIL iframe.marginWidth: IDL set to null followed by getAttribute() assert_equals: expected "" but got "null"
-FAIL iframe.marginWidth: IDL set to null followed by IDL get assert_equals: expected "" but got "null"
+PASS iframe.marginWidth: IDL set to null followed by getAttribute()
+PASS iframe.marginWidth: IDL set to null followed by IDL get
PASS iframe.marginWidth: IDL set to object "test-toString" should not throw
PASS iframe.marginWidth: IDL set to object "test-toString" followed by getAttribute()
PASS iframe.marginWidth: IDL set to object "test-toString" followed by IDL get
Modified: trunk/Source/WebCore/ChangeLog (203523 => 203524)
--- trunk/Source/WebCore/ChangeLog 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/Source/WebCore/ChangeLog 2016-07-21 21:10:35 UTC (rev 203524)
@@ -1,5 +1,23 @@
2016-07-21 Chris Dumez <[email protected]>
+ Fix null handling for HTMLIFrameElement.marginWidth / marginHeight
+ https://bugs.webkit.org/show_bug.cgi?id=160037
+
+ Reviewed by Ryosuke Niwa.
+
+ Fix null handling for HTMLIFrameElement.marginWidth / marginHeight to
+ match the specification:
+ - https://html.spec.whatwg.org/#HTMLIFrameElement-partial
+
+ We are supposed to treat null as the empty string. Both Firefox and
+ Chrome agree with the specification.
+
+ No new tests, rebaselined existing tests.
+
+ * html/HTMLIFrameElement.idl:
+
+2016-07-21 Chris Dumez <[email protected]>
+
Fix null handling for HTMLImageElement.border
https://bugs.webkit.org/show_bug.cgi?id=160039
Modified: trunk/Source/WebCore/html/HTMLIFrameElement.idl (203523 => 203524)
--- trunk/Source/WebCore/html/HTMLIFrameElement.idl 2016-07-21 21:09:44 UTC (rev 203523)
+++ trunk/Source/WebCore/html/HTMLIFrameElement.idl 2016-07-21 21:10:35 UTC (rev 203524)
@@ -23,8 +23,8 @@
[Reflect] attribute DOMString frameBorder;
[Reflect] attribute DOMString height;
[Reflect] attribute DOMString longDesc;
- [Reflect] attribute DOMString marginHeight;
- [Reflect] attribute DOMString marginWidth;
+ [Reflect, TreatNullAs=EmptyString] attribute DOMString marginHeight;
+ [Reflect, TreatNullAs=EmptyString] attribute DOMString marginWidth;
[Reflect] attribute DOMString name;
#if defined(LANGUAGE_OBJECTIVE_C) && LANGUAGE_OBJECTIVE_C || defined(LANGUAGE_GOBJECT) && LANGUAGE_GOBJECT