2011-05-24 Jay Civelli <jcivelli@chromium.org>
[WebKit-https.git] / LayoutTests / accessibility / crash-with-noelement-selectbox.html
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <link rel="stylesheet" href="../fast/js/resources/js-test-style.css">
5 <script>
6 var successfullyParsed = false;
7 </script>
8 <script src="../fast/js/resources/js-test-pre.js"></script>
9 </head>
10 <body id="body">
11
12 <select id="selectBox">
13 </select>
14 <p id="description"></p>
15 <div id="console"></div>
16
17 <script>
18
19     description("This tests that there's no crash when accessising the stringValue of a menu list that has no elements.");
20
21     if (window.accessibilityController) {
22        document.getElementById("selectBox").focus();
23        var selectBox = accessibilityController.focusedElement;
24
25        // this call should not crash. 
26        var stringValue = selectBox.stringValue;
27     }
28
29     successfullyParsed = true;
30 </script>
31
32 <script src="../fast/js/resources/js-test-post.js"></script>
33 </body>
34 </html>