Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / accessibility / button-title-uses-inner-img-alt.html
blobe9aa803ac5acbae8af5d4cf24d58ecf5644b4682
1 <!DOCTYPE HTML>
2 <html>
3 <body>
4 <script src="../resources/js-test.js"></script>
6 <style>
7 button {
8 padding: 30px;
10 </style>
12 <button id="cake">Button with image of <img alt="cake" src="resources/cake.png" width="40px"></button>
14 <div id="console"></div>
15 <script>
16 description("This test makes sure that a generic focusable div can get accessibility focus and gets its accessible text from contents..");
18 if (window.testRunner && window.accessibilityController) {
19 window.testRunner.dumpAsText();
21 var button = document.getElementById('cake');
22 button.focus();
23 shouldBe("document.activeElement == button", "true");
24 window.axButton = accessibilityController.focusedElement;
25 shouldBe("axButton.deprecatedTitle.indexOf('Button with image of cake') >= 0", "true");
28 </script>
30 </body>
31 </html>