| OLD | NEW |
| 1 <html xmlns="http://www.w3.org/1999/xhtml"> | 1 <html xmlns="http://www.w3.org/1999/xhtml"> |
| 2 <head> | 2 <head> |
| 3 <style type="text/css"> | 3 <style type="text/css"> |
| 4 .pass { color: green; } | 4 .pass { color: green; } |
| 5 .fail { color: red; } | 5 .fail { color: red; } |
| 6 </style> | 6 </style> |
| 7 <script type="text/javascript" charset="utf-8"> | 7 <script type="text/javascript" charset="utf-8"> |
| 8 function printOut(msg) | 8 function printOut(msg) |
| 9 { | 9 { |
| 10 var console = document.getElementById("console"); | 10 var console = document.getElementById("console"); |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 | 49 |
| 50 var listing = [ | 50 var listing = [ |
| 51 { | 51 { |
| 52 type: 'SVGElement', | 52 type: 'SVGElement', |
| 53 elementToUse: svg, | 53 elementToUse: svg, |
| 54 attributes: [ | 54 attributes: [ |
| 55 {name: 'id', expectedNull: 'null'}, | 55 {name: 'id', expectedNull: 'null'}, |
| 56 ] | 56 ] |
| 57 }, | 57 }, |
| 58 { | 58 { |
| 59 type: 'SVGAngle', | |
| 60 elementToUse: svg.createSVGAngle(), | |
| 61 attributes: [ | |
| 62 {name: 'valueAsString', expectedNull: '0'} | |
| 63 ] | |
| 64 }, | |
| 65 { | |
| 66 type: 'SVGLength', | |
| 67 elementToUse: svg.createSVGLength(), | |
| 68 attributes: [ | |
| 69 {name: 'valueAsString', expectedNull: '0'} | |
| 70 ] | |
| 71 }, | |
| 72 { | |
| 73 type: 'SVGScriptElement', | 59 type: 'SVGScriptElement', |
| 74 elementToUse: document.createElementNS(svgNS, 'script'), | 60 elementToUse: document.createElementNS(svgNS, 'script'), |
| 75 attributes: [ | 61 attributes: [ |
| 76 {name: 'type', expectedNull: 'null'} | 62 {name: 'type', expectedNull: 'null'} |
| 77 ] | 63 ] |
| 78 } | 64 } |
| 79 ]; | 65 ]; |
| 80 | 66 |
| 81 for (element in listing) { | 67 for (element in listing) { |
| 82 var type = listing[element].type; | 68 var type = listing[element].type; |
| 83 var elementToUse = listing[element].elementToUse; | 69 var elementToUse = listing[element].elementToUse; |
| 84 var attrs = listing[element].attributes; | 70 var attrs = listing[element].attributes; |
| 85 for (attr in attrs) { | 71 for (attr in attrs) { |
| 86 nullTestElementAttribute(type, elementToUse, attrs[attr].nam
e, attrs[attr].expectedNull); | 72 nullTestElementAttribute(type, elementToUse, attrs[attr].nam
e, attrs[attr].expectedNull); |
| 87 } | 73 } |
| 88 printOut(''); | 74 printOut(''); |
| 89 } | 75 } |
| 90 } | 76 } |
| 91 | 77 |
| 92 </script> | 78 </script> |
| 93 </head> | 79 </head> |
| 94 | 80 |
| 95 <body onload="runTests();"> | 81 <body onload="runTests();"> |
| 96 <p>This test setting various attributes of a SVG elements to JavaScript null
.</p> | 82 <p>This test setting various attributes of a SVG elements to JavaScript null
.</p> |
| 97 <div id="console"></div> | 83 <div id="console"></div> |
| 98 </body> | 84 </body> |
| 99 </html> | 85 </html> |
| OLD | NEW |