Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(403)

Side by Side Diff: third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/valueMode.html

Issue 2695813009: Import wpt@503f5b5f78ec4e87d144f78609f363f0ed0ea8db (Closed)
Patch Set: Skip some tests Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <meta charset=utf-8> 2 <meta charset=utf-8>
3 <title>Input element value mode</title> 3 <title>Input element value mode</title>
4 <link rel="author" title="Denis Ah-Kang" href="mailto:denis@w3.org"> 4 <link rel="author" title="Denis Ah-Kang" href="mailto:denis@w3.org">
5 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script> 6 <script src="/resources/testharnessreport.js"></script>
7 <div id="log"></div> 7 <div id="log"></div>
8 <script> 8 <script>
9 // MODE DEFAULT 9 // MODE DEFAULT
10 test(function () { 10 test(function () {
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 input.setAttribute("value", "bar"); 75 input.setAttribute("value", "bar");
76 input.value = "foo"; 76 input.value = "foo";
77 assert_equals(input.value, "foo"); 77 assert_equals(input.value, "foo");
78 }, "value IDL attribute of input type button with value attribute"); 78 }, "value IDL attribute of input type button with value attribute");
79 79
80 // MODE DEFAULT/ON 80 // MODE DEFAULT/ON
81 test(function () { 81 test(function () {
82 var input = document.createElement("input"); 82 var input = document.createElement("input");
83 input.type = "checkbox"; 83 input.type = "checkbox";
84 input.value = "foo"; 84 input.value = "foo";
85 assert_equals(input.value, "on"); 85 assert_equals(input.value, "foo");
86 }, "value IDL attribute of input type checkbox without value attribute"); 86 }, "value IDL attribute of input type checkbox without value attribute");
87 test(function() { 87 test(function() {
88 var input = document.createElement("input"); 88 var input = document.createElement("input");
89 input.type = "checkbox"; 89 input.type = "checkbox";
90 input.setAttribute("value", "bar"); 90 input.setAttribute("value", "bar");
91 input.value = "foo"; 91 input.value = "foo";
92 assert_equals(input.value, "bar"); 92 assert_equals(input.value, "foo");
93 }, "value IDL attribute of input type checkbox with value attribute"); 93 }, "value IDL attribute of input type checkbox with value attribute");
94 94
95 test(function () { 95 test(function () {
96 var input = document.createElement("input"); 96 var input = document.createElement("input");
97 input.type = "radio"; 97 input.type = "radio";
98 input.value = "foo"; 98 input.value = "foo";
99 assert_equals(input.value, "on"); 99 assert_equals(input.value, "foo");
100 }, "value IDL attribute of input type radio without value attribute"); 100 }, "value IDL attribute of input type radio without value attribute");
101 test(function() { 101 test(function() {
102 var input = document.createElement("input"); 102 var input = document.createElement("input");
103 input.type = "radio"; 103 input.type = "radio";
104 input.setAttribute("value", "bar"); 104 input.setAttribute("value", "bar");
105 input.value = "foo"; 105 input.value = "foo";
106 assert_equals(input.value, "bar"); 106 assert_equals(input.value, "foo");
107 }, "value IDL attribute of input type radio with value attribute"); 107 }, "value IDL attribute of input type radio with value attribute");
108 108
109 // MODE VALUE 109 // MODE VALUE
110 test(function () { 110 test(function () {
111 var input = document.createElement("input"); 111 var input = document.createElement("input");
112 input.type = "text"; 112 input.type = "text";
113 input.value = "foo"; 113 input.value = "foo";
114 assert_equals(input.value, "foo"); 114 assert_equals(input.value, "foo");
115 }, "value IDL attribute of input type text without value attribute"); 115 }, "value IDL attribute of input type text without value attribute");
116 test(function() { 116 test(function() {
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 assert_equals(input.value, "#000000"); 296 assert_equals(input.value, "#000000");
297 }, "value IDL attribute of input type color without value attribute"); 297 }, "value IDL attribute of input type color without value attribute");
298 test(function() { 298 test(function() {
299 var input = document.createElement("input"); 299 var input = document.createElement("input");
300 input.type = "color"; 300 input.type = "color";
301 input.setAttribute("value", "bar"); 301 input.setAttribute("value", "bar");
302 input.value = "foo"; 302 input.value = "foo";
303 assert_equals(input.value, "#000000"); 303 assert_equals(input.value, "#000000");
304 }, "value IDL attribute of input type color with value attribute"); 304 }, "value IDL attribute of input type color with value attribute");
305 </script> 305 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698