Title: [125250] trunk/LayoutTests
Revision
125250
Author
[email protected]
Date
2012-08-09 22:00:19 -0700 (Thu, 09 Aug 2012)

Log Message

Add DOMString reflection test
https://bugs.webkit.org/show_bug.cgi?id=93681

Reviewed by Hajime Morita.

Introduce fast/dom/domstring-atribute-reflection.html, which
should have tess for all of reflected DOMString IDL attribute,
like fast/dom/boolean-attribute-reflection.html and
URL-attribute-reflectin.html.

As the first step, integrate fast/forms/input-step.html and
fast/form/name-attribute.html into
domstring-attribute-reflection.html.

* fast/dom/domstring-attribute-reflection-expected.txt: Renamed from LayoutTests/fast/forms/name-attribute-expected.txt.
* fast/dom/domstring-attribute-reflection.html: Added.
* fast/forms/input-step-expected.txt: Removed.
* fast/forms/input-step.html: Removed.
* fast/forms/name-attribute.html: Removed.

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (125249 => 125250)


--- trunk/LayoutTests/ChangeLog	2012-08-10 04:53:50 UTC (rev 125249)
+++ trunk/LayoutTests/ChangeLog	2012-08-10 05:00:19 UTC (rev 125250)
@@ -1,3 +1,25 @@
+2012-08-09  Kent Tamura  <[email protected]>
+
+        Add DOMString reflection test
+        https://bugs.webkit.org/show_bug.cgi?id=93681
+
+        Reviewed by Hajime Morita.
+
+        Introduce fast/dom/domstring-atribute-reflection.html, which
+        should have tess for all of reflected DOMString IDL attribute,
+        like fast/dom/boolean-attribute-reflection.html and
+        URL-attribute-reflectin.html.
+
+        As the first step, integrate fast/forms/input-step.html and
+        fast/form/name-attribute.html into
+        domstring-attribute-reflection.html.
+
+        * fast/dom/domstring-attribute-reflection-expected.txt: Renamed from LayoutTests/fast/forms/name-attribute-expected.txt.
+        * fast/dom/domstring-attribute-reflection.html: Added.
+        * fast/forms/input-step-expected.txt: Removed.
+        * fast/forms/input-step.html: Removed.
+        * fast/forms/name-attribute.html: Removed.
+
 2012-08-09  Sukolsak Sakshuwong  <[email protected]>
 
         Mouse-select then Cut, results in preceding character being lost

Copied: trunk/LayoutTests/fast/dom/domstring-attribute-reflection-expected.txt (from rev 125249, trunk/LayoutTests/fast/forms/name-attribute-expected.txt) (0 => 125250)


--- trunk/LayoutTests/fast/dom/domstring-attribute-reflection-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/fast/dom/domstring-attribute-reflection-expected.txt	2012-08-10 05:00:19 UTC (rev 125250)
@@ -0,0 +1,304 @@
+Reflected DOMString attribute test for button/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for fieldset/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for form/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for input/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for input/@step
+Initial value:
+PASS element.step is ""
+PASS element.getAttribute("step") is null
+Setting a value via the IDL attribute:
+PASS element.step = "foo"; element.step is "foo"
+PASS element.getAttribute("step") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("step", " bar\n"); element.step is " bar\n"
+PASS element.getAttribute("step") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.step = null; element.step is ""
+PASS element.getAttribute("step") is null
+Setting null via the content attribute:
+PASS element.setAttribute("step", null); element.step is "null"
+PASS element.getAttribute("step") is "null"
+Setting undefined via the IDL attribute:
+PASS element.step = undefined; element.step is "undefined"
+PASS element.getAttribute("step") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("step", undefined); element.step is "undefined"
+PASS element.getAttribute("step") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.step = 123; element.step is "123"
+PASS element.getAttribute("step") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("step", 456); element.step is "456"
+PASS element.getAttribute("step") is "456"
+
+
+Reflected DOMString attribute test for keygen/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for object/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for output/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for select/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+Reflected DOMString attribute test for textarea/@name
+Initial value:
+PASS element.name is ""
+PASS element.getAttribute("name") is null
+Setting a value via the IDL attribute:
+PASS element.name = "foo"; element.name is "foo"
+PASS element.getAttribute("name") is "foo"
+Setting a value via the content attribute:
+PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
+PASS element.getAttribute("name") is " bar\n"
+Setting null via the IDL attribute:
+PASS element.name = null; element.name is ""
+PASS element.getAttribute("name") is null
+Setting null via the content attribute:
+PASS element.setAttribute("name", null); element.name is "null"
+PASS element.getAttribute("name") is "null"
+Setting undefined via the IDL attribute:
+PASS element.name = undefined; element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting undefined via the content attribute:
+PASS element.setAttribute("name", undefined); element.name is "undefined"
+PASS element.getAttribute("name") is "undefined"
+Setting non-string via the IDL attribute:
+PASS element.name = 123; element.name is "123"
+PASS element.getAttribute("name") is "123"
+Setting non-string via the content attribute:
+PASS element.setAttribute("name", 456); element.name is "456"
+PASS element.getAttribute("name") is "456"
+
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+

Added: trunk/LayoutTests/fast/dom/domstring-attribute-reflection.html (0 => 125250)


--- trunk/LayoutTests/fast/dom/domstring-attribute-reflection.html	                        (rev 0)
+++ trunk/LayoutTests/fast/dom/domstring-attribute-reflection.html	2012-08-10 05:00:19 UTC (rev 125250)
@@ -0,0 +1,67 @@
+<!DOCTYPE html>
+<html>
+<body>
+<script src=""
+<script>
+var element;
+
+function testDOMStringReflection(elementName, contentAttributeName, idlAttributeName) {
+    idlAttributeName = idlAttributeName || contentAttributeName;
+    element = document.createElement(elementName);
+    debug('Reflected DOMString attribute test for ' + elementName + '/@' + contentAttributeName);
+    debug('Initial value:');
+    shouldBeEqualToString('element.' + idlAttributeName, '');
+    shouldBeNull('element.getAttribute("' + contentAttributeName + '")');
+
+    debug('Setting a value via the IDL attribute:');
+    shouldBeEqualToString('element.' + idlAttributeName + ' = "foo"; element.' + idlAttributeName, 'foo');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', 'foo');
+
+    debug('Setting a value via the content attribute:');
+    shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '", " bar\\n"); element.' + idlAttributeName, ' bar\n');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', ' bar\n');
+
+    debug('Setting null via the IDL attribute:');
+    shouldBeEqualToString('element.' + idlAttributeName + ' = null; element.' + idlAttributeName, '');
+    shouldBeNull('element.getAttribute("' + contentAttributeName + '")');
+
+    debug('Setting null via the content attribute:');
+    shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '", null); element.' + idlAttributeName, 'null');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', 'null');
+
+    debug('Setting undefined via the IDL attribute:');
+    shouldBeEqualToString('element.' + idlAttributeName + ' = undefined; element.' + idlAttributeName, 'undefined');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', 'undefined');
+
+    debug('Setting undefined via the content attribute:');
+    shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '", undefined); element.' + idlAttributeName, 'undefined');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', 'undefined');
+
+    debug('Setting non-string via the IDL attribute:');
+    shouldBeEqualToString('element.' + idlAttributeName + ' = 123; element.' + idlAttributeName, '123');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', '123');
+
+    debug('Setting non-string via the content attribute:');
+    shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '", 456); element.' + idlAttributeName, '456');
+    shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")', '456');
+
+    debug('\n');
+}
+
+testDOMStringReflection('button', 'name');
+testDOMStringReflection('fieldset', 'name');
+testDOMStringReflection('form', 'name');
+testDOMStringReflection('input', 'name');
+testDOMStringReflection('input', 'step');
+testDOMStringReflection('keygen', 'name');
+testDOMStringReflection('object', 'name');
+testDOMStringReflection('output', 'name');
+testDOMStringReflection('select', 'name');
+testDOMStringReflection('textarea', 'name');
+
+// Add more DOMString attributes!
+
+</script>
+<script src=""
+</body>
+</html>

Deleted: trunk/LayoutTests/fast/forms/input-step-expected.txt (125249 => 125250)


--- trunk/LayoutTests/fast/forms/input-step-expected.txt	2012-08-10 04:53:50 UTC (rev 125249)
+++ trunk/LayoutTests/fast/forms/input-step-expected.txt	2012-08-10 05:00:19 UTC (rev 125250)
@@ -1,21 +0,0 @@
-Test the behavior of step attribute and step DOM property.
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-
-PASS input.step is ""
-PASS input.getAttribute("step") is "foo"
-PASS input.step is "bar"
-PASS input.step is ""
-PASS input.getAttribute("step") is null
-PASS input.step is "null"
-PASS input.step is "undefined"
-PASS input.getAttribute("step") is "undefined"
-PASS input.step is "undefined"
-PASS input.step is "256"
-PASS input.getAttribute("step") is "256"
-PASS input.step is "256"
-PASS successfullyParsed is true
-
-TEST COMPLETE
-

Deleted: trunk/LayoutTests/fast/forms/input-step.html (125249 => 125250)


--- trunk/LayoutTests/fast/forms/input-step.html	2012-08-10 04:53:50 UTC (rev 125249)
+++ trunk/LayoutTests/fast/forms/input-step.html	2012-08-10 05:00:19 UTC (rev 125250)
@@ -1,47 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
-<html>
-<head>
-<script src=""
-</head>
-<body>
-<p id="description"></p>
-<div id="console"></div>
-<script>
-description('Test the behavior of step attribute and step DOM property.');
-
-var input = document.createElement('input');
-input.type = 'number';
-
-// No step attribute.
-shouldBe('input.step', '""');
-
-// Set an invalid step value.
-input.step = 'foo';
-shouldBe('input.getAttribute("step")', '"foo"');
-input.setAttribute('step', 'bar');
-shouldBe('input.step', '"bar"');
-
-// Null.
-input.step = null;
-shouldBe('input.step', '""');
-shouldBe('input.getAttribute("step")', 'null');
-input.setAttribute('step', null);
-shouldBe('input.step', '"null"');
-
-// Undefined.
-input.step = undefined;
-shouldBe('input.step', '"undefined"');
-shouldBe('input.getAttribute("step")', '"undefined"');
-input.setAttribute('step', undefined);
-shouldBe('input.step', '"undefined"');
-
-// Non-string.
-input.step = 256;
-shouldBe('input.step', '"256"');
-shouldBe('input.getAttribute("step")', '"256"');
-input.setAttribute('step', 256);
-shouldBe('input.step', '"256"');
-</script>
-<script src=""
-</body>
-</html>

Deleted: trunk/LayoutTests/fast/forms/name-attribute-expected.txt (125249 => 125250)


--- trunk/LayoutTests/fast/forms/name-attribute-expected.txt	2012-08-10 04:53:50 UTC (rev 125249)
+++ trunk/LayoutTests/fast/forms/name-attribute-expected.txt	2012-08-10 05:00:19 UTC (rev 125250)
@@ -1,279 +0,0 @@
-Check behavior of name attribute for various form elements
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-
-Test cases for button
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for fieldset
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for form
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for input
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for keygen
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for object
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for output
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for select
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-Test cases for textarea
-Initial value:
-PASS element.name is ""
-PASS element.getAttribute("name") is null
-Setting a value via the IDL attribute:
-PASS element.name = "foo"; element.name is "foo"
-PASS element.getAttribute("name") is "foo"
-Setting a value via the content attribute:
-PASS element.setAttribute("name", " bar\n"); element.name is " bar\n"
-PASS element.getAttribute("name") is " bar\n"
-Setting null via the IDL attribute:
-PASS element.name = null; element.name is ""
-PASS element.getAttribute("name") is null
-Setting null via the content attribute:
-PASS element.setAttribute("name", null); element.name is "null"
-PASS element.getAttribute("name") is "null"
-Setting undefined via the IDL attribute:
-PASS element.name = undefined; element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting undefined via the content attribute:
-PASS element.setAttribute("name", undefined); element.name is "undefined"
-PASS element.getAttribute("name") is "undefined"
-Setting non-string via the IDL attribute:
-PASS element.name = 123; element.name is "123"
-PASS element.getAttribute("name") is "123"
-Setting non-string via the content attribute:
-PASS element.setAttribute("name", 456); element.name is "456"
-PASS element.getAttribute("name") is "456"
-
-
-PASS successfullyParsed is true
-
-TEST COMPLETE
-

Deleted: trunk/LayoutTests/fast/forms/name-attribute.html (125249 => 125250)


--- trunk/LayoutTests/fast/forms/name-attribute.html	2012-08-10 04:53:50 UTC (rev 125249)
+++ trunk/LayoutTests/fast/forms/name-attribute.html	2012-08-10 05:00:19 UTC (rev 125250)
@@ -1,48 +0,0 @@
-<!DOCTYPE html>
-<script src=""
-<script>
-description("Check behavior of name attribute for various form elements");
-var elementNames = ["button", "fieldset", "form", "input", "keygen", "object", "output", "select", "textarea"];
-for (var i = 0; i < elementNames.length; ++i) {
-    var element = document.createElement(elementNames[i]);
-    debug('Test cases for ' + elementNames[i]);
-    debug('Initial value:');
-    shouldBeEqualToString('element.name', '');
-    shouldBeNull('element.getAttribute("name")');
-
-    debug('Setting a value via the IDL attribute:');
-    shouldBeEqualToString('element.name = "foo"; element.name', 'foo');
-    shouldBeEqualToString('element.getAttribute("name")', 'foo');
-
-    debug('Setting a value via the content attribute:');
-    shouldBeEqualToString('element.setAttribute("name", " bar\\n"); element.name', ' bar\n');
-    shouldBeEqualToString('element.getAttribute("name")', ' bar\n');
-
-    debug('Setting null via the IDL attribute:');
-    shouldBeEqualToString('element.name = null; element.name', '');
-    shouldBeNull('element.getAttribute("name")');
-
-    debug('Setting null via the content attribute:');
-    shouldBeEqualToString('element.setAttribute("name", null); element.name', 'null');
-    shouldBeEqualToString('element.getAttribute("name")', 'null');
-
-    debug('Setting undefined via the IDL attribute:');
-    shouldBeEqualToString('element.name = undefined; element.name', 'undefined');
-    shouldBeEqualToString('element.getAttribute("name")', 'undefined');
-
-    debug('Setting undefined via the content attribute:');
-    shouldBeEqualToString('element.setAttribute("name", undefined); element.name', 'undefined');
-    shouldBeEqualToString('element.getAttribute("name")', 'undefined');
-
-    debug('Setting non-string via the IDL attribute:');
-    shouldBeEqualToString('element.name = 123; element.name', '123');
-    shouldBeEqualToString('element.getAttribute("name")', '123');
-
-    debug('Setting non-string via the content attribute:');
-    shouldBeEqualToString('element.setAttribute("name", 456); element.name', '456');
-    shouldBeEqualToString('element.getAttribute("name")', '456');
-
-    debug('\n');
-}
-</script>
-<script src=""
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to