Index: chrome/test/pyautolib/pyauto.py |
diff --git a/chrome/test/pyautolib/pyauto.py b/chrome/test/pyautolib/pyauto.py |
index 9e179f6d7b74b87ca637ab356482d42ee5dc60f9..f4c804a0761144847e39a361c96eca083b700a86 100644 |
--- a/chrome/test/pyautolib/pyauto.py |
+++ b/chrome/test/pyautolib/pyauto.py |
@@ -1790,6 +1790,22 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase): |
} |
self._GetResultFromJSONRequest(cmd_dict) |
+ def TriggerExtensionActionById(self, id, windex=0): |
+ """Trigger browser/page action asynchronously in the active tab. |
+ |
+ If the extension has a page action, the page action icon must be displayed. |
dennis_jeffrey
2011/11/17 00:53:17
nit: ...the page action icon must be displayed bef
frankf
2011/11/21 02:01:46
Done.
|
+ |
+ Args: |
+ id: The string id of the extension. |
+ windex: Integer index of the browser window to use; defaults to 0 |
+ (first window). |
+ """ |
+ cmd_dict = { # Prepare command for the json interface |
+ 'command': 'TriggerExtensionActionById', |
+ 'id': id, |
+ } |
+ self._GetResultFromJSONRequest(cmd_dict, windex=windex) |
+ |
def UpdateExtensionsNow(self): |
"""Auto-updates installed extensions. |