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

Unified Diff: chrome/browser/resources/sync_setup_overlay.js

Issue 8503003: Seed test for SyncUI: sign in successfully with mocks. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Use makeAndRegisterMockHandler in new ChromeSendWebUITest. Created 9 years, 1 month 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/resources/sync_setup_overlay.js
diff --git a/chrome/browser/resources/sync_setup_overlay.js b/chrome/browser/resources/sync_setup_overlay.js
index 8e3a955ae29d5ba284dfb55c43b003fb1dade555..2304970456250114e89afcbdae29e91031a21428 100644
--- a/chrome/browser/resources/sync_setup_overlay.js
+++ b/chrome/browser/resources/sync_setup_overlay.js
@@ -561,6 +561,33 @@ cr.define('options', function() {
}
},
+ /**
+ * Get the login email text input DOM element.
+ * @return {DOMElement} The login email text input.
+ * @private
+ */
+ getLoginEmail_: function() {
+ return $('gaia-email');
+ },
+
+ /**
+ * Get the login password text input DOM element.
+ * @return {DOMElement} The login password text input.
+ * @private
+ */
+ getLoginPasswd_: function() {
+ return $('gaia-passwd');
+ },
+
+ /**
+ * Get the sign in button DOM element.
+ * @return {DOMElement} The sign in button.
+ * @private
+ */
+ getSignInButton_: function() {
+ return $('sign-in');
+ },
+
showAccessCodeRequired_: function() {
$('password-row').hidden = true;
$('email-row').hidden = true;
@@ -819,6 +846,20 @@ cr.define('options', function() {
}
};
+ // These get methods should only be called by the WebUI tests.
+ SyncSetupOverlay.getLoginEmail = function() {
+ return SyncSetupOverlay.getInstance().getLoginEmail_();
+ };
+
+ SyncSetupOverlay.getLoginPasswd = function() {
+ return SyncSetupOverlay.getInstance().getLoginPasswd_();
+ };
+
+ SyncSetupOverlay.getSignInButton = function() {
+ return SyncSetupOverlay.getInstance().getSignInButton_();
+ };
+
+ // These methods are for general consumption.
SyncSetupOverlay.showErrorUI = function() {
SyncSetupOverlay.getInstance().showErrorUI_();
};
« no previous file with comments | « chrome/browser/resources/options/personal_options.js ('k') | chrome/browser/ui/webui/options/options_browsertest.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698