OLD | NEW |
1 <html> | 1 <html> |
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> | 7 <script> |
8 function printOut(msg) | 8 function printOut(msg) |
9 { | 9 { |
10 var console = document.getElementById("console"); | 10 var console = document.getElementById("console"); |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 {name: 'coords', expectedNull: 'null'}, | 128 {name: 'coords', expectedNull: 'null'}, |
129 {name: 'href', expectedNull: 'null', isUrl: true}, | 129 {name: 'href', expectedNull: 'null', isUrl: true}, |
130 {name: 'shape', expectedNull: 'null'}, | 130 {name: 'shape', expectedNull: 'null'}, |
131 {name: 'target', expectedNull: 'null'} | 131 {name: 'target', expectedNull: 'null'} |
132 ] | 132 ] |
133 }, | 133 }, |
134 { | 134 { |
135 type: 'HTMLAudioElement', | 135 type: 'HTMLAudioElement', |
136 elementToUse: document.createElement('audio'), | 136 elementToUse: document.createElement('audio'), |
137 attributes: [ | 137 attributes: [ |
138 {name: 'mediaGroup', expectedNull: 'null'}, | |
139 {name: 'preload', expectedNull: 'auto'}, | 138 {name: 'preload', expectedNull: 'auto'}, |
140 {name: 'src', expectedNull: 'null', isUrl: true} | 139 {name: 'src', expectedNull: 'null', isUrl: true} |
141 ] | 140 ] |
142 }, | 141 }, |
143 { | 142 { |
144 type: 'HTMLBaseElement', | 143 type: 'HTMLBaseElement', |
145 elementToUse: document.createElement('base'), | 144 elementToUse: document.createElement('base'), |
146 attributes: [ | 145 attributes: [ |
147 {name: 'href', expectedNull: 'null', isUrl: true}, | 146 {name: 'href', expectedNull: 'null', isUrl: true}, |
148 {name: 'target', expectedNull: 'null'} | 147 {name: 'target', expectedNull: 'null'} |
(...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
662 type: 'HTMLUListElement', | 661 type: 'HTMLUListElement', |
663 elementToUse: document.createElement('ul'), | 662 elementToUse: document.createElement('ul'), |
664 attributes: [ | 663 attributes: [ |
665 {name: 'type', expectedNull: 'null'} | 664 {name: 'type', expectedNull: 'null'} |
666 ] | 665 ] |
667 }, | 666 }, |
668 { | 667 { |
669 type: 'HTMLVideoElement', | 668 type: 'HTMLVideoElement', |
670 elementToUse: document.createElement('video'), | 669 elementToUse: document.createElement('video'), |
671 attributes: [ | 670 attributes: [ |
672 {name: 'mediaGroup', expectedNull: 'null'}, | |
673 {name: 'poster', expectedNull: 'null', isUrl: true}, | 671 {name: 'poster', expectedNull: 'null', isUrl: true}, |
674 {name: 'preload', expectedNull: 'auto'}, | 672 {name: 'preload', expectedNull: 'auto'}, |
675 {name: 'src', expectedNull: 'null', isUrl: true} | 673 {name: 'src', expectedNull: 'null', isUrl: true} |
676 ] | 674 ] |
677 } | 675 } |
678 ]; | 676 ]; |
679 | 677 |
680 for (element in listing) { | 678 for (element in listing) { |
681 var type = listing[element].type; | 679 var type = listing[element].type; |
682 var elementToUse = listing[element].elementToUse; | 680 var elementToUse = listing[element].elementToUse; |
683 var attrs = listing[element].attributes; | 681 var attrs = listing[element].attributes; |
684 for (attr in attrs) { | 682 for (attr in attrs) { |
685 nullTestElementAttribute(type, elementToUse, attrs[attr].nam
e, attrs[attr].expectedNull, attrs[attr].isUrl); | 683 nullTestElementAttribute(type, elementToUse, attrs[attr].nam
e, attrs[attr].expectedNull, attrs[attr].isUrl); |
686 } | 684 } |
687 printOut(''); | 685 printOut(''); |
688 } | 686 } |
689 } | 687 } |
690 </script> | 688 </script> |
691 </head> | 689 </head> |
692 <body onload="runTests()"> | 690 <body onload="runTests()"> |
693 <p>This test setting various attributes of a elements to JavaScript null.</p
> | 691 <p>This test setting various attributes of a elements to JavaScript null.</p
> |
694 <div id="console"></div> | 692 <div id="console"></div> |
695 </body> | 693 </body> |
696 </html> | 694 </html> |
OLD | NEW |