OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script src="../../js/resources/js-test-pre.js"></script> | 4 <script src="../../../resources/js-test.js"></script> |
5 </head> | 5 </head> |
6 <body> | 6 <body> |
7 <select id="tags"> | 7 <select id="tags"> |
8 <option selected="selected" value="marquee">marquee</option> | 8 <option selected="selected" value="marquee">marquee</option> |
9 <option value="blink">blink</option> | 9 <option value="blink">blink</option> |
10 </select> | 10 </select> |
11 <script> | 11 <script> |
12 description('Check if an option is removed when it is assigned null.'); | 12 description('Check if an option is removed when it is assigned null.'); |
13 var tags = document.getElementById('tags'); | 13 var tags = document.getElementById('tags'); |
14 shouldBe("tags.options.length", "2"); | 14 shouldBe("tags.options.length", "2"); |
15 | 15 |
16 tags[0] = null; | 16 tags[0] = null; |
17 shouldBe("tags.options.length", "1"); | 17 shouldBe("tags.options.length", "1"); |
18 | 18 |
19 tags[tags.length] = new Option("bgsound", "bgsound"); | 19 tags[tags.length] = new Option("bgsound", "bgsound"); |
20 shouldBe("tags.options.length", "2"); | 20 shouldBe("tags.options.length", "2"); |
21 </script> | 21 </script> |
22 </body> | 22 </body> |
23 </html> | 23 </html> |
OLD | NEW |