Commit 12adc787 authored by tkent@chromium.org's avatar tkent@chromium.org

AX: Calendar Picker: Update a test for button descriptions.

BUG=123896

Review URL: https://codereview.chromium.org/561673002

git-svn-id: svn://svn.chromium.org/blink/trunk@181792 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 971fdb21
......@@ -8,6 +8,10 @@ Focused: AXDescription: Sunday, January 2, 2000
PASS Received ActiveDescendantChanged
Focused: AXDescription: Monday, January 3, 2000
PASS Received ActiveDescendantChanged
Focused: AXDescription: Show next month
Focused: AXDescription: <<CalendarToday>>
Focused: AXDescription: Show previous month
Focused: AXDescription: Show month selection panel
PASS successfullyParsed is true
TEST COMPLETE
......
......@@ -13,11 +13,11 @@ description('Tests if typing an arrow key dispatches |Focus| and |ActiveDescenda
window.accessibilityController.setNotificationListener(function(axnode, type) {
if (type == 'Focus') {
debug('Focused: ' + accessibilityController.focusedElement.description);
debug('Focused: ' + escapeHTML(accessibilityController.focusedElement.description));
} else if (type == 'ActiveDescendantChanged') {
testPassed('Received ActiveDescendantChanged');
if (++activeDescendantCounter >= 2)
finishJSTest();
if (++activeDescendantCounter == 2)
testButtonDescription();
}
});
var activeDescendantCounter = 0;
......@@ -27,6 +27,18 @@ openPicker(date1, test1);
function test1() {
eventSender.keyDown('rightArrow');
}
function testButtonDescription() {
// Focus on 'next month' button.
eventSender.keyDown('\t', ['shiftKey']);
// Focus on the today button.
eventSender.keyDown('\t', ['shiftKey']);
// Focus on 'previous month' button.
eventSender.keyDown('\t', ['shiftKey']);
// Focus on the month selector button.
eventSender.keyDown('\t', ['shiftKey']);
setTimeout(finishJSTest, 0);
}
</script>
</body>
</html>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment