| <html> |
| <body> |
| <script> |
| if (window.testRunner) |
| testRunner.dumpAsText(); |
| |
| function validateRole() { |
| if (!window.accessibilityController) |
| return; |
| |
| var aria = document.getElementById("slider"); |
| aria.focus(); |
| var ariaRole = accessibilityController.focusedElement.role; |
| |
| var result = document.getElementById("result"); |
| if (ariaRole == "AXRole: AXSlider") |
| result.innerText = "This test PASSES in DumpRenderTree. The role is " + ariaRole; |
| else |
| result.innerText = "This test FAILS in DumpRenderTree. The ARIA role is " + ariaRole + ", but should be AXSlider"; |
| } |
| </script> |
| |
| <div> |
| <p>In accessibility, the following should be a progress indicator:</p> |
| <p><span tabindex="0" role="slider" id="slider" aria-valuenow=5 aria-valuemin=0 aria-valuemax=10>X</span></p> |
| <span id="result"></span> |
| <script> |
| validateRole(); |
| </script> |
| </div> |
| |
| </body> |
| </html> |