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

Unified Diff: chrome/test/pyautolib/pyauto.py

Issue 6994005: Fix password automation hooks to get pyauto test testSavePassword working. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Disabling a single pyauto passwords test. Created 9 years, 7 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/pyautolib/pyauto.py
diff --git a/chrome/test/pyautolib/pyauto.py b/chrome/test/pyautolib/pyauto.py
index cdc8b8cbf12973c0252857c383bfe34fa5a4777a..872a8935ae26abc46b27180993195a5b0f779ee4 100644
--- a/chrome/test/pyautolib/pyauto.py
+++ b/chrome/test/pyautolib/pyauto.py
@@ -1674,7 +1674,7 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase):
}
return self._GetResultFromJSONRequest(cmd_dict)
- def AddSavedPassword(self, password_dict, window_index=0):
+ def AddSavedPassword(self, password_dict, windex=0):
"""Adds the given username-password combination to the saved passwords.
Args:
@@ -1689,7 +1689,7 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase):
'submit_element': 'submit', # The HTML element
'action_target': 'https://www.example.com/login/',
'blacklist': False }
- window_index: window index, defaults to 0
+ windex: window index; defaults to 0 (first window).
*Blacklist notes* To blacklist a site, add a blacklist password with the
following dictionary items: origin_url, signon_realm, username_element,
@@ -1701,14 +1701,14 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase):
mode, adding the password should fail.
Raises:
- JSONInterfaceError on error.
+ pyauto_errors.JSONInterfaceError if the automation call returns an error.
"""
cmd_dict = { # Prepare command for the json interface
'command': 'AddSavedPassword',
'password': password_dict
}
return self._GetResultFromJSONRequest(
- cmd_dict, windex=window_index)['password_added']
+ cmd_dict, windex=windex)['password_added']
def RemoveSavedPassword(self, password_dict, window_index=0):
"""Removes the password matching the provided password dictionary.

Powered by Google App Engine
This is Rietveld 408576698