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

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

Issue 2170583002: MD Settings: fix route query in tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove instead Created 4 years, 5 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 | « no previous file | chrome/test/data/webui/settings/settings_page_browsertest.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/webui/settings/languages_page_browsertest.js
diff --git a/chrome/test/data/webui/settings/languages_page_browsertest.js b/chrome/test/data/webui/settings/languages_page_browsertest.js
index a03eaa3d0f764dfb9e80bdb83e9098c5353cdd83..f1aa4328f5ed2296f737bb53da4f073f6fcea768 100644
--- a/chrome/test/data/webui/settings/languages_page_browsertest.js
+++ b/chrome/test/data/webui/settings/languages_page_browsertest.js
@@ -67,11 +67,18 @@ TEST_F('SettingsLanguagesPageBrowserTest', 'MAYBE_LanguagesPage', function() {
}.bind(this));
teardown(function(done) {
tommycli 2016/07/20 22:16:15 This teardown is needed to navigate back after eac
michaelpg 2016/07/20 22:40:08 yes, adjusted the comment
- if (this.isAtRoot())
- return done();
- this.backToRoot();
- setTimeout(done);
- }.bind(this));
+ if (advanced.currentRoute.subpage.length == 0) {
+ done();
+ } else {
+ // Close the section.
+ advanced.currentRoute = {
+ page: 'advanced',
+ section: '',
+ subpage: [],
+ };
+ setTimeout(done);
tommycli 2016/07/20 22:16:15 Does advanced.async make more sense?
michaelpg 2016/07/20 22:40:08 No, the tests can become flaky that way. I think w
+ }
+ });
test('manage languages', function() {
var manageLanguagesButton =
« no previous file with comments | « no previous file | chrome/test/data/webui/settings/settings_page_browsertest.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698