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

Side by Side Diff: chrome/browser/ui/webui/signin/login_ui_test_utils.h

Issue 1102603003: Enable new sign in flow for E2E tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix DomMessageQueue usage Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/webui/signin/login_ui_test_utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_
6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_ 6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 class Browser; 10 class Browser;
11 11
12 namespace login_ui_test_utils { 12 namespace login_ui_test_utils {
13 13
14 // Blocks until the login UI is available and ready for authorization. 14 // Blocks until the login UI is available and ready for authorization.
15 void WaitUntilUIReady(Browser* browser); 15 void WaitUntilUIReady(Browser* browser);
16 16
17 // Blocks until an element with id |element_id| exists in the signin page.
18 void WaitUntilElementExistsInSigninFrame(Browser* browser,
19 const std::string& element_id);
20
21 // Returns whether an element with id |element_id| exists in the signin page.
22 bool ElementExistsInSigninFrame(Browser* browser,
23 const std::string& element_id);
24
17 // Executes JavaScript code to sign in a user with email and password to the 25 // Executes JavaScript code to sign in a user with email and password to the
18 // auth iframe hosted by gaia_auth extension. 26 // auth iframe hosted by gaia_auth extension. This function automatically
27 // detects the version of GAIA sign in page to use.
19 void ExecuteJsToSigninInSigninFrame(Browser* browser, 28 void ExecuteJsToSigninInSigninFrame(Browser* browser,
20 const std::string& email, 29 const std::string& email,
21 const std::string& password); 30 const std::string& password);
22 31
32 // Executes JS to sign in the user in the new GAIA sign in flow.
33 void SigninInNewGaiaFlow(Browser* browser,
34 const std::string& email,
35 const std::string& password);
36
37 // Executes JS to sign in the user in the old GAIA sign in flow.
38 void SigninInOldGaiaFlow(Browser* browser,
39 const std::string& email,
40 const std::string& password);
41
23 // A function to sign in a user using Chrome sign-in UI interface. 42 // A function to sign in a user using Chrome sign-in UI interface.
24 // This will block until a signin succeeded or failed notification is observed. 43 // This will block until a signin succeeded or failed notification is observed.
25 bool SignInWithUI(Browser* browser, 44 bool SignInWithUI(Browser* browser,
26 const std::string& email, 45 const std::string& email,
27 const std::string& password); 46 const std::string& password);
28 47
29 } // namespace login_ui_test_utils 48 } // namespace login_ui_test_utils
30 49
31 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_ 50 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_LOGIN_UI_TEST_UTILS_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/webui/signin/login_ui_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698