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

Unified Diff: chrome/test/data/webui/settings/reset_page_test.js

Issue 1911573003: MD Settings: Reset profile dialog, display settings in new tab. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments. Created 4 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 | « chrome/browser/ui/webui/settings/reset_settings_handler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/webui/settings/reset_page_test.js
diff --git a/chrome/test/data/webui/settings/reset_page_test.js b/chrome/test/data/webui/settings/reset_page_test.js
index ffe3271c3e5144257e5ad3ea73588ab876f09f0c..dd21beabcd7b2876978b0a6a4f27e7a0ccde89ed 100644
--- a/chrome/test/data/webui/settings/reset_page_test.js
+++ b/chrome/test/data/webui/settings/reset_page_test.js
@@ -24,6 +24,7 @@ cr.define('settings_reset_page', function() {
'onHideResetProfileDialog',
'onHideResetProfileBanner',
'onShowResetProfileDialog',
+ 'getReportedSettings',
'onPowerwashDialogShow',
'requestFactoryResetRestart',
]);
@@ -54,6 +55,12 @@ cr.define('settings_reset_page', function() {
},
/** @override */
+ getReportedSettings: function() {
+ this.methodCalled('getReportedSettings');
+ return Promise.resolve([]);
+ },
+
+ /** @override */
onPowerwashDialogShow: function() {
this.methodCalled('onPowerwashDialogShow');
},
@@ -184,8 +191,15 @@ cr.define('settings_reset_page', function() {
MockInteractions.tap(resetPage.$.resetProfile);
var dialog = resetPage.$$('settings-reset-profile-dialog');
assertTrue(!!dialog);
- MockInteractions.tap(dialog.$.reset);
- return browserProxy.whenCalled('performResetProfileSettings');
+
+ var showReportedSettingsButton = dialog.$$('iron-icon');
+ assertTrue(!!showReportedSettingsButton);
+ MockInteractions.tap(showReportedSettingsButton);
+
+ return browserProxy.whenCalled('getReportedSettings').then(function() {
+ MockInteractions.tap(dialog.$.reset);
+ return browserProxy.whenCalled('performResetProfileSettings');
+ });
});
if (cr.isChromeOS) {
« no previous file with comments | « chrome/browser/ui/webui/settings/reset_settings_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698