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

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: Added comments and moved gaia login to test. 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..4864d3245eedb07ca8cf0974f6e3df1f1956838f 100644
--- a/chrome/browser/resources/sync_setup_overlay.js
+++ b/chrome/browser/resources/sync_setup_overlay.js
@@ -561,6 +561,30 @@ cr.define('options', function() {
}
},
+ /**
+ * Get the login email text input DOM element.
James Hawkins 2011/11/10 00:24:43 @private, here and elsewhere.
Sheridan Rawlins 2011/11/10 02:02:12 Done.
+ * @return {DOMElement} The login email text input.
+ */
+ getLoginEmail_: function() {
+ return $('gaia-email');
+ },
+
+ /**
+ * Get the login password text input DOM element.
+ * @return {DOMElement} The login password text input.
+ */
+ getLoginPasswd_: function() {
+ return $('gaia-passwd');
+ },
+
+ /**
+ * Get the sign in button DOM element.
+ * @return {DOMElement} The sign in button.
+ */
+ getSignInButton_: function() {
+ return $('sign-in');
+ },
+
showAccessCodeRequired_: function() {
$('password-row').hidden = true;
$('email-row').hidden = true;
@@ -819,6 +843,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_();
};

Powered by Google App Engine
This is Rietveld 408576698