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

Unified 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 side-by-side diff with in-line comments
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 »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/signin/login_ui_test_utils.h
diff --git a/chrome/browser/ui/webui/signin/login_ui_test_utils.h b/chrome/browser/ui/webui/signin/login_ui_test_utils.h
index 3f17f46c0968dfd66e0cc518c27601962c595b11..bf9a11051041af161ad1597ee3b8be20de348c58 100644
--- a/chrome/browser/ui/webui/signin/login_ui_test_utils.h
+++ b/chrome/browser/ui/webui/signin/login_ui_test_utils.h
@@ -14,12 +14,31 @@ namespace login_ui_test_utils {
// Blocks until the login UI is available and ready for authorization.
void WaitUntilUIReady(Browser* browser);
+// Blocks until an element with id |element_id| exists in the signin page.
+void WaitUntilElementExistsInSigninFrame(Browser* browser,
+ const std::string& element_id);
+
+// Returns whether an element with id |element_id| exists in the signin page.
+bool ElementExistsInSigninFrame(Browser* browser,
+ const std::string& element_id);
+
// Executes JavaScript code to sign in a user with email and password to the
-// auth iframe hosted by gaia_auth extension.
+// auth iframe hosted by gaia_auth extension. This function automatically
+// detects the version of GAIA sign in page to use.
void ExecuteJsToSigninInSigninFrame(Browser* browser,
const std::string& email,
const std::string& password);
+// Executes JS to sign in the user in the new GAIA sign in flow.
+void SigninInNewGaiaFlow(Browser* browser,
+ const std::string& email,
+ const std::string& password);
+
+// Executes JS to sign in the user in the old GAIA sign in flow.
+void SigninInOldGaiaFlow(Browser* browser,
+ const std::string& email,
+ const std::string& password);
+
// A function to sign in a user using Chrome sign-in UI interface.
// This will block until a signin succeeded or failed notification is observed.
bool SignInWithUI(Browser* browser,
« 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