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

Unified Diff: LayoutTests/accessibility/menu-list-optgroup.html

Issue 1059503002: Re-land: Don't keep recreating AXMenuListPopup (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@suppress_extra_events
Patch Set: Fix optgroup Created 5 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 | LayoutTests/accessibility/menu-list-popup-reuses-objects.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/accessibility/menu-list-optgroup.html
diff --git a/LayoutTests/accessibility/menu-list-optgroup.html b/LayoutTests/accessibility/menu-list-optgroup.html
new file mode 100644
index 0000000000000000000000000000000000000000..01bcc4399e9977f8a16c337d5316bc7addd353bf
--- /dev/null
+++ b/LayoutTests/accessibility/menu-list-optgroup.html
@@ -0,0 +1,29 @@
+<!DOCTYPE HTML>
+<script src="../resources/testharness.js"></script>
+<script src="../resources/testharnessreport.js"></script>
+<select id="menulist">
+ <option>Random Transformer</option>
+ <optgroup>
+ <option>Optimus Prime</option>
+ <option>Bumblebee</option>
+ <option>Jazz</option>
+ </optgroup>
+ <optgroup>
+ <option>Megatron</option>
+ <option>Starscream</option>
+ <option>Brawl</option>
+ </optgroup>
+</select>
+<script>
+test(function(t)
+{
+ var axMenuList = accessibilityController.accessibleElementById("menulist");
+ assert_equals(axMenuList.role, "AXRole: AXPopUpButton");
+ var axMenuListPopup = axMenuList.childAtIndex(0);
+ assert_equals(axMenuListPopup.role, "AXRole: AXMenuListPopup");
+ assert_equals(axMenuListPopup.childrenCount, 7);
+ for (var i = 0; i < axMenuListPopup.childrenCount; i++) {
+ assert_equals(axMenuListPopup.childAtIndex(i).role, "AXRole: AXMenuListOption");
+ }
+}, "menu list optgroup options are accessible");
+</script>
« no previous file with comments | « no previous file | LayoutTests/accessibility/menu-list-popup-reuses-objects.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698