Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(40)

Unified Diff: third_party/WebKit/LayoutTests/accessibility/aria-row-name.html

Issue 2805343002: Compute accessible name of objects with ARIA role of 'row' if they can receive focus (Closed)
Patch Set: Add negative test Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXObject.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/accessibility/aria-row-name.html
diff --git a/third_party/WebKit/LayoutTests/accessibility/aria-row-name.html b/third_party/WebKit/LayoutTests/accessibility/aria-row-name.html
new file mode 100644
index 0000000000000000000000000000000000000000..02e65c0713539ef7b3f5ddf070b4ea094cf97866
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/accessibility/aria-row-name.html
@@ -0,0 +1,45 @@
+<!DOCTYPE HTML>
+<script src="../resources/testharness.js"></script>
+<script src="../resources/testharnessreport.js"></script>
+<body id="body">
+<div role="treegrid">
+ <div role="row" id="treegrid1-row1" tabindex="-1">
+ <div role="rowheader">row head</div>
+ <div role="gridcell">data</div>
+ </div>
+</div>
+<div role="treegrid" aria-activedescendant="treegrid2-row1">
+ <div role="row" id="treegrid2-row1">
+ <div role="rowheader">row head</div>
+ <div role="gridcell">data</div>
+ </div>
+</div>
+<div role="grid">
+ <div role="row" id="treegrid3-row1">
+ <div role="rowheader">row head</div>
+ <div role="gridcell">data</div>
+ </div>
+</div>
+</body>
+
+<script>
+function axElementById(id) {
+ return accessibilityController.accessibleElementById(id);
+}
+
+test(function(t) {
+ var axRow = axElementById("treegrid1-row1");
+ assert_equals(axRow.name, 'row head data');
+}, "The row's name must concatenate the children if the row is focusable");
+
+test(function(t) {
+ var axRow = axElementById("treegrid2-row1");
+ assert_equals(axRow.name, 'row head data');
+}, "The row's name must concatenate the children if the parent has aria-activedescendant");
+
+test(function(t) {
+ var axRow = axElementById("treegrid3-row1");
+ assert_equals(axRow.name, '');
+}, "The row's name must empty when the parent is not focusable and there is no other labelling markup (for performance reasons)");
+
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698