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

Unified Diff: chrome/browser/chromeos/login/saml/saml_browsertest.cc

Issue 2478803003: Remove DOMAutomationController::automation_id_ (Closed)
Patch Set: Rebasing... Created 3 years, 5 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/browser/chromeos/login/saml/saml_browsertest.cc
diff --git a/chrome/browser/chromeos/login/saml/saml_browsertest.cc b/chrome/browser/chromeos/login/saml/saml_browsertest.cc
index c05eba90bbee2b20a1790e0f7d44f575f30a3583..a63586f62e0290774c103046815491e482014664 100644
--- a/chrome/browser/chromeos/login/saml/saml_browsertest.cc
+++ b/chrome/browser/chromeos/login/saml/saml_browsertest.cc
@@ -358,16 +358,16 @@ class SamlTest : public OobeBaseTest {
}
void SetupAuthFlowChangeListener() {
- ASSERT_TRUE(content::ExecuteScript(
+ content::ExecuteScriptAsync(
GetLoginUI()->GetWebContents(),
"$('gaia-signin').gaiaAuthHost_.addEventListener('authFlowChange',"
- "function f() {"
- "$('gaia-signin').gaiaAuthHost_.removeEventListener("
- "'authFlowChange', f);"
- "window.domAutomationController.setAutomationId(0);"
- "window.domAutomationController.send("
- "$('gaia-signin').isSAML() ? 'SamlLoaded' : 'GaiaLoaded');"
- "});"));
+ " function f() {"
+ " $('gaia-signin').gaiaAuthHost_.removeEventListener("
+ " 'authFlowChange', f);"
+ " window.domAutomationController.setAutomationId(0);"
+ " window.domAutomationController.send("
+ " $('gaia-signin').isSAML() ? 'SamlLoaded' : 'GaiaLoaded');"
+ " });");
}
virtual void StartSamlAndWaitForIdpPageLoad(const std::string& gaia_email) {
@@ -463,9 +463,8 @@ IN_PROC_BROWSER_TEST_F(SamlTest, MAYBE_SamlUI) {
// Click on 'cancel'.
content::DOMMessageQueue message_queue; // Observe before 'cancel'.
- ASSERT_TRUE(
- content::ExecuteScript(GetLoginUI()->GetWebContents(),
- "$('gaia-navigation').$.closeButton.click();"));
+ content::ExecuteScriptAsync(GetLoginUI()->GetWebContents(),
+ "$('gaia-navigation').$.closeButton.click();");
// Auth flow should change back to Gaia.
std::string message;

Powered by Google App Engine
This is Rietveld 408576698