Index: third_party/WebKit/LayoutTests/accessibility/focusable-div.html |
diff --git a/third_party/WebKit/LayoutTests/accessibility/focusable-div.html b/third_party/WebKit/LayoutTests/accessibility/focusable-div.html |
index a04be0a4dfc800339358552b43e6dc945823365f..242d0fc3750227059d76defd405ad2790d7fa8fa 100644 |
--- a/third_party/WebKit/LayoutTests/accessibility/focusable-div.html |
+++ b/third_party/WebKit/LayoutTests/accessibility/focusable-div.html |
@@ -6,12 +6,10 @@ |
<!-- A link always gets its accessible text from contents. --> |
<a id="link" href="#">A</a> |
-<!-- A generic focusable div should also get its accessible text from contents. --> |
+<!-- A generic focusable div not get its accessible text from contents. --> |
<div id="div" tabindex="0">B</div> |
<div id="div2" tabindex="0"><div></div>C</div> |
<div id="div3" tabindex="0" aria-label="D"></div> |
- |
-<!-- A generic focusable div should not get accessible text from children that are focusable or containers. --> |
<div id="div4" tabindex="0"><a href="#">Link</a></div> |
<div id="div5" tabindex="0">Initial text before link<a href="#">Link</a></div> |
<div id="div6" tabindex="0"><ul><li>List item</li></ul></div> |
@@ -24,59 +22,53 @@ description("This test makes sure that a generic focusable div can get accessibi |
if (window.testRunner && window.accessibilityController) { |
window.testRunner.dumpAsText(); |
- function lastChar(str) { |
- return str.substr(str.length - 1); |
- } |
- |
var link = document.getElementById('link'); |
link.focus(); |
shouldBe("document.activeElement == link", "true"); |
window.axLink = accessibilityController.focusedElement; |
- shouldBe("lastChar(axLink.deprecatedTitle)", "\"A\""); |
+ shouldBe("axLink.name", "\"A\""); |
var div = document.getElementById('div'); |
div.focus(); |
shouldBe("document.activeElement == div", "true"); |
window.axDiv = accessibilityController.focusedElement; |
- shouldBe("lastChar(axDiv.deprecatedTitle)", "\"B\""); |
+ shouldBe("axDiv.name", "\"\""); |
var div2 = document.getElementById('div2'); |
div2.focus(); |
shouldBe("document.activeElement == div2", "true"); |
window.axDiv2 = accessibilityController.focusedElement; |
- shouldBe("lastChar(axDiv2.deprecatedTitle)", "\"C\""); |
+ shouldBe("axDiv2.name", "\"\""); |
var div3 = document.getElementById('div3'); |
div3.focus(); |
shouldBe("document.activeElement == div3", "true"); |
window.axDiv3 = accessibilityController.focusedElement; |
- shouldBe("lastChar(axDiv3.deprecatedDescription)", "\"D\""); |
+ shouldBe("axDiv3.name", "\"D\""); |
var div4 = document.getElementById('div4'); |
div4.focus(); |
shouldBe("document.activeElement == div4", "true"); |
window.axDiv4 = accessibilityController.focusedElement; |
- shouldBe("axDiv4.deprecatedTitle.indexOf('Link')", "-1"); |
+ shouldBe("axDiv4.name", "\"\""); |
var div5 = document.getElementById('div5'); |
div5.focus(); |
shouldBe("document.activeElement == div5", "true"); |
window.axDiv5 = accessibilityController.focusedElement; |
- shouldBe("axDiv5.deprecatedTitle.indexOf('Link')", "-1"); |
- shouldBe("axDiv5.deprecatedTitle.indexOf('Initial text before link') >= 0", "true"); |
+ shouldBe("axDiv5.name", "\"\""); |
var div6 = document.getElementById('div6'); |
div6.focus(); |
shouldBe("document.activeElement == div6", "true"); |
window.axDiv6 = accessibilityController.focusedElement; |
- shouldBe("axDiv6.deprecatedTitle.indexOf('List item')", "-1"); |
+ shouldBe("axDiv6.name", "\"\""); |
var div7 = document.getElementById('div7'); |
div7.focus(); |
shouldBe("document.activeElement == div7", "true"); |
window.axDiv7 = accessibilityController.focusedElement; |
- shouldBe("axDiv7.deprecatedTitle.indexOf('List item')", "-1"); |
- shouldBe("axDiv7.deprecatedTitle.indexOf('Initial text before list') >= 0", "true"); |
+ shouldBe("axDiv7.name", "\"\""); |
} |
</script> |