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

Unified Diff: chrome/test/functional/chromeos_login.py

Issue 10944014: Fix to enable the cached credentials login test (Closed) Base URL: https://git.chromium.org/git/chromium/src@master
Patch Set: Replaced hook with boolean switch v2 Created 8 years, 3 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/functional/chromeos_login.py
diff --git a/chrome/test/functional/chromeos_login.py b/chrome/test/functional/chromeos_login.py
index 7b4a56bcb658b4504f30fc316c53008aa32aa3cf..86546f4a53a885f77b3d2f046d67c5b8f2fce9a4 100755
--- a/chrome/test/functional/chromeos_login.py
+++ b/chrome/test/functional/chromeos_login.py
@@ -317,7 +317,7 @@ class ChromeosLoginCachedCredentialsAddUser(pyauto.PyUITest):
credentials['password'])
)
-class ChromeosLoginCachedCredentialsUserPod(pyauto.PyUITest):
+class ChromeosLoginCachedCredentialsUserPod(ChromeosLogin):
Nirnimesh 2012/09/21 18:46:43 why?
beeps 2012/09/26 18:31:09 wanted to reuse testGoodLogin, have duplicated it
"""TestCase for Logging into ChromeOS with cached credentials and
invalid proxy settings.
"""
@@ -331,7 +331,7 @@ class ChromeosLoginCachedCredentialsUserPod(pyauto.PyUITest):
# so restart ui now.
cros_ui.stop(allow_fail=True)
cryptohome.remove_all_vaults()
- cros_ui.start(wait_for_login_prompt=False)
+ cros_ui.start(wait_for_login_prompt=True)
pyauto.PyUITest.setUp(self)
def tearDown(self):
@@ -354,12 +354,17 @@ class ChromeosLoginCachedCredentialsUserPod(pyauto.PyUITest):
make it pass we need a hook that simply calls Login on the delegate
in webui_login_display.cc ::ShowSigninScreenForCreds.
"""
+ credentials = self._ValidCredentials()
self.testGoodLogin()
self.Logout()
- self.SetProxySettingOnChromeOS('singlehttp', '127.0.0.1')
- self.testGoodLogin()
- self.ResetProxySettingsOnChromeOS()
-
+ proxy_dict = {
+ 'url_path': 'singlehttp',
+ 'proxy_url': '127.0.0.1',
+ }
+ self.SetProxySettingOnChromeOS(proxy_dict)
+ self.pyauto.Login(credentials['username'], credentials['password'], True)
Nirnimesh 2012/09/21 18:46:43 prefer named args. username=credentials['username'
beeps 2012/09/26 18:31:09 Done.
+ login_info = self.GetLoginInfo()
+ self.assertTrue(login_info['is_logged_in'], msg='Login failed.')
if __name__ == '__main__':
pyauto_functional.Main()

Powered by Google App Engine
This is Rietveld 408576698