Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / forms / select-max-length.html
blobf18c83f8be9aaa4cc7b122c7bae6b24d15b091f2
1 <p>This test that setting HTMLSelectElement.length is capped to 10,000, but that you can add additional Option elements by calling add.</p>
2 <div id="console"></div>
3 <select id="theSelect"></select>
4 <script src="../../resources/js-test.js"></script>
5 <script>
6 var sel = document.getElementById('theSelect');
7 shouldBe('sel.length', '0');
9 debug('Trying: - sel.length = 20000;');
10 sel.length = 20000;
11 shouldBe('sel.length', '0');
13 debug('Trying: - sel.add(new Option, 0);');
14 sel.add(new Option, 0);
15 shouldBe('sel.length', '1');
17 debug('Trying: - sel.length = 0;');
18 sel.length = 0;
19 shouldBe('sel.length', '0');
21 debug('Index setter:');
22 shouldBe('sel[20000] = new Option(); sel.length', '0');
23 shouldBe('sel.options[20000] = new Option(); sel.length', '0');
24 </script>