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

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

Issue 2226313003: Settings Router Refactor: Remove one last stray subpage-back. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 4 years, 4 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/resources/settings/settings_page/settings_subpage.js ('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/cr_settings_browsertest.js
diff --git a/chrome/test/data/webui/settings/cr_settings_browsertest.js b/chrome/test/data/webui/settings/cr_settings_browsertest.js
index d117682d795ac62c49d9f112cfb74276be250288..1dd36378ea1af0f607579e598d0f957f8089e2d5 100644
--- a/chrome/test/data/webui/settings/cr_settings_browsertest.js
+++ b/chrome/test/data/webui/settings/cr_settings_browsertest.js
@@ -545,6 +545,40 @@ TEST_F('CrSettingsMenuTest', 'SettingsMenu', function() {
mocha.run();
});
+/**
+ * Test fixture for
+ * chrome/browser/resources/settings/settings_page/settings_subpage.html.
+ * @constructor
+ * @extends {CrSettingsBrowserTest}
+*/
+function CrSettingsSubpageTest() {}
+
+CrSettingsSubpageTest.prototype = {
+ __proto__: CrSettingsBrowserTest.prototype,
+
+ /** @override */
+ browsePreload: 'chrome://md-settings/settings_page/settings_subpage.html',
+};
+
+TEST_F('CrSettingsSubpageTest', 'SettingsSubpage', function() {
+ suite('SettingsSubpage', function() {
+ test('can navigate to parent', function() {
+ PolymerTest.clearBody();
+
+ settings.navigateTo(settings.Route.SYNC);
+ assertEquals(settings.Route.SYNC, settings.getCurrentRoute());
+
+ var subpage = document.createElement('settings-subpage');
+ document.body.appendChild(subpage);
+
+ MockInteractions.tap(subpage.$$('paper-icon-button'));
+ assertEquals(settings.Route.PEOPLE, settings.getCurrentRoute());
+ });
+ });
+
+ mocha.run();
+});
+
GEN('#if !defined(OS_CHROMEOS)');
/**
* @constructor
« no previous file with comments | « chrome/browser/resources/settings/settings_page/settings_subpage.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698