OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <script src="../fast/js/resources/js-test-pre.js"></script> | 3 <script src="../resources/js-test.js"></script> |
4 </head> | 4 </head> |
5 <script> | 5 <script> |
6 if (window.testRunner) | 6 if (window.testRunner) |
7 testRunner.dumpAsText(); | 7 testRunner.dumpAsText(); |
8 </script> | 8 </script> |
9 <body id="body"> | 9 <body id="body"> |
10 | 10 |
11 <img id='image' src="resources/cake.png" role="button" alt="alternate" title
="title"> | 11 <img id='image' src="resources/cake.png" role="button" alt="alternate" title
="title"> |
12 | 12 |
13 <p id="description"></p> | 13 <p id="description"></p> |
14 <div id="console"></div> | 14 <div id="console"></div> |
15 | 15 |
16 <script> | 16 <script> |
17 description("This test makes sure that a img acting as an aria button st
ill returns its alt tag as the description"); | 17 description("This test makes sure that a img acting as an aria button st
ill returns its alt tag as the description"); |
18 | 18 |
19 if (window.accessibilityController) { | 19 if (window.accessibilityController) { |
20 var result = document.getElementById("result"); | 20 var result = document.getElementById("result"); |
21 | 21 |
22 var body = document.getElementById("body").focus(); | 22 var body = document.getElementById("body").focus(); |
23 var imgUIElement = accessibilityController.focusedElement.childAtInd
ex(0).childAtIndex(0); | 23 var imgUIElement = accessibilityController.focusedElement.childAtInd
ex(0).childAtIndex(0); |
24 shouldBe("imgUIElement.description", "'AXDescription: alternate'"); | 24 shouldBe("imgUIElement.description", "'AXDescription: alternate'"); |
25 } | 25 } |
26 </script> | 26 </script> |
27 | 27 |
28 </body> | 28 </body> |
29 </html> | 29 </html> |
OLD | NEW |