[go: nahoru, domu]

blob: c9d334a22df3d3c9cbb4028f09ec0ddddf989dcc [file] [log] [blame]
<html>
<script>
if (window.testRunner)
testRunner.dumpAsText();
</script>
<body id="body">
<!-- This test makes sure that a secure text field has the correct title ui element -->
<label for="accountpassword"><span class="dslabel">Password</span></label><br>
<input size="30" maxlength="32" id="accountpassword" type="password" name="theAccountPW">
<div id="result"></div>
<script>
if (window.accessibilityController) {
var result = document.getElementById("result");
var pass = document.getElementById("accountpassword");
pass.focus();
var titleUIElement = accessibilityController.focusedElement.nameElementAtIndex(0);
var titleText = titleUIElement.childAtIndex(0);
if (titleText.name == "Password") {
result.innerText += "Test passed\n";
}
else {
result.innerText += "Test failed\n";
}
}
</script>
</body>
</html>