Chromium Code Reviews| Index: chrome/browser/ui/webui/options/options_browsertest.js |
| diff --git a/chrome/browser/ui/webui/options/options_browsertest.js b/chrome/browser/ui/webui/options/options_browsertest.js |
| index 591771f0972cec2b4d78f944ee7846d293605575..1f890691f1290b0e58f922080c1e9e590fbc8f92 100644 |
| --- a/chrome/browser/ui/webui/options/options_browsertest.js |
| +++ b/chrome/browser/ui/webui/options/options_browsertest.js |
| @@ -636,6 +636,22 @@ TEST_F('OptionsWebUIExtendedTest', 'CloseOverlay', function() { |
| }); |
| }); |
| +// Test that closing an overlay that did not push history when opening does not |
| +// again push history. |
| +TEST_F('OptionsWebUIExtendedTest', 'CloseOverlayNoHistory', function() { |
| + // Open the profile delete prompt. |
| + ManageProfileOverlay.showDeleteDialog(BrowserOptions.getCurrentProfile()); |
| + |
| + // Opening the prompt does not add to the history. |
| + var self = this; |
| + this.verifyHistory_([''], function() { |
| + // Close the overlay. |
| + OptionsPage.closeOverlay(); |
| + // Still no history changes. |
| + self.verifyHistory_([''], testDone); |
| + }); |
|
Dan Beam
2014/05/30 21:13:17
nit: instead of making |self|
this.verifyHistor
davidben
2014/05/30 21:20:36
Done. (Cool, I'm glad that's how we should be doin
|
| +}); |
| + |
| // Make sure an overlay isn't closed (even temporarily) when another overlay is |
| // opened on top. |
| TEST_F('OptionsWebUIExtendedTest', 'OverlayAboveNoReset', function() { |