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

Unified Diff: chrome/test/data/extensions/api_test/automation/sanity_check/test.js

Issue 203753002: Implement actions for Automation API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Disable test on Mac. Created 6 years, 9 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
Index: chrome/test/data/extensions/api_test/automation/sanity_check/test.js
diff --git a/chrome/test/data/extensions/api_test/automation/sanity_check/test.js b/chrome/test/data/extensions/api_test/automation/sanity_check/test.js
index 3cf6d289d6d869d1348e1aad1a2d765e3b093d78..be3eadf045d2789516f2ec1bad019f73947aeee9 100644
--- a/chrome/test/data/extensions/api_test/automation/sanity_check/test.js
+++ b/chrome/test/data/extensions/api_test/automation/sanity_check/test.js
@@ -94,6 +94,22 @@ var allTests = [
});
});
});
+ },
+ function testSimpleAction() {
+ function makeAssertions(tree) {
+ var okButton = tree.root.firstChild().firstChild();
+ okButton.addEventListener('focus', function() {
+ chrome.test.succeed();
+ }, true);
+ okButton.focus();
+ }
+ chrome.tabs.create({url: 'test.html'});
+ chrome.automation.getTree(function(tree) {
+ tree.root.addEventListener('load_complete',
+ function() {
+ makeAssertions(tree);
+ }, true);
+ });
}
];

Powered by Google App Engine
This is Rietveld 408576698