2008-11-04 Anders Carlsson <andersca@apple.com>
[webkit/qt.git] / LayoutTests / fast / dom / HTMLSelectElement / options-collection-set-string-length.html
blobf19a18ef940a70ddf71390f25fc1026365afb031
1 <html>
2 <head>
3 <script>
4 function log(msg)
6 document.getElementById('console').appendChild(document.createTextNode(msg + '\n'));
9 function test()
11 if (window.layoutTestController)
12 layoutTestController.dumpAsText();
14 var sl = document.getElementById("sl");
15 sl.options.length="5";
16 if (sl.options.length == 5)
17 log("Test Passed");
18 else
19 log("Test Failed");
21 </script>
22 </head>
23 <body onload="test()">
24 This tests that setting the options collection length to a string representation of a number works.<br>
25 <select id="sl"><option>This option should be visible</select>
26 <pre id="console"></pre>
27 </body>
28 </html>