OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <body> | 3 <body> |
4 <script src="../../resources/js-test.js"></script> | 4 <script src="../../resources/js-test.js"></script> |
5 <script> | 5 <script> |
6 var element; | 6 var element; |
7 | 7 |
8 function testDOMStringReflection(elementName, contentAttributeName, idlAttribute
Name, treatNullAsString) { | 8 function testDOMStringReflection(elementName, contentAttributeName, idlAttribute
Name, treatNullAsString) { |
9 idlAttributeName = idlAttributeName || contentAttributeName; | 9 idlAttributeName = idlAttributeName || contentAttributeName; |
10 element = document.createElement(elementName); | 10 element = document.createElement(elementName); |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 debug('Setting non-string via the content attribute:'); | 49 debug('Setting non-string via the content attribute:'); |
50 shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '",
456); element.' + idlAttributeName, '456'); | 50 shouldBeEqualToString('element.setAttribute("' + contentAttributeName + '",
456); element.' + idlAttributeName, '456'); |
51 shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")'
, '456'); | 51 shouldBeEqualToString('element.getAttribute("' + contentAttributeName + '")'
, '456'); |
52 | 52 |
53 debug('\n'); | 53 debug('\n'); |
54 } | 54 } |
55 | 55 |
56 testDOMStringReflection('button', 'name', 'name', true); | 56 testDOMStringReflection('button', 'name', 'name', true); |
57 testDOMStringReflection('fieldset', 'name', 'name', true); | 57 testDOMStringReflection('fieldset', 'name', 'name', true); |
58 testDOMStringReflection('form', 'name', 'name', true); | 58 testDOMStringReflection('form', 'name', 'name', true); |
59 testDOMStringReflection('input', 'name'); | 59 testDOMStringReflection('input', 'name', 'name', true); |
60 testDOMStringReflection('input', 'step'); | 60 testDOMStringReflection('input', 'step', 'step', true); |
61 testDOMStringReflection('keygen', 'name', 'name', true); | 61 testDOMStringReflection('keygen', 'name', 'name', true); |
62 testDOMStringReflection('object', 'name'); | 62 testDOMStringReflection('object', 'name'); |
63 testDOMStringReflection('output', 'name', 'name', true); | 63 testDOMStringReflection('output', 'name', 'name', true); |
64 testDOMStringReflection('select', 'name'); | 64 testDOMStringReflection('select', 'name'); |
65 testDOMStringReflection('textarea', 'name'); | 65 testDOMStringReflection('textarea', 'name'); |
66 | 66 |
67 // Add more DOMString attributes! | 67 // Add more DOMString attributes! |
68 | 68 |
69 </script> | 69 </script> |
70 </body> | 70 </body> |
71 </html> | 71 </html> |
OLD | NEW |