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

Unified Diff: chrome/browser/ui/webui/uber/uber_ui_browsertest.cc

Issue 1766273002: Convert --enable-md-history to a feature flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update tests to use the new feature flags instead of the existing Created 4 years, 9 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
Index: chrome/browser/ui/webui/uber/uber_ui_browsertest.cc
diff --git a/chrome/browser/ui/webui/uber/uber_ui_browsertest.cc b/chrome/browser/ui/webui/uber/uber_ui_browsertest.cc
index 14bc2c7f76d4da911f79f644d36dfbb40d222bc2..ae1de022ec0f8c292c419b7ad18068504ae3d157 100644
--- a/chrome/browser/ui/webui/uber/uber_ui_browsertest.cc
+++ b/chrome/browser/ui/webui/uber/uber_ui_browsertest.cc
@@ -16,6 +16,7 @@
#include "chrome/common/url_constants.h"
#include "chrome/test/base/ui_test_utils.h"
#include "chrome/test/base/web_ui_browser_test.h"
+#include "content/public/common/content_switches.h"
#include "content/public/test/browser_test_utils.h"
#include "extensions/browser/extension_registry.h"
#include "extensions/common/extension.h"
@@ -44,6 +45,12 @@ class UberUIBrowserTest : public WebUIBrowserTest {
"uber.invokeMethodOnWindow(this, 'changeSelection', data);");
}
+ void SetUpCommandLine(base::CommandLine* command_line) override {
+ command_line->AppendSwitchASCII(
+ ::switches::kEnableFeatures,
+ ::switches::kMaterialDesignHistoryFeature.name);
+ }
+
private:
content::WebContents* GetWebContents() {
return browser()->tab_strip_model()->GetActiveWebContents();
@@ -92,8 +99,6 @@ IN_PROC_BROWSER_TEST_F(UberUIBrowserTest, EnableMdExtensionsHidesExtensions) {
}
IN_PROC_BROWSER_TEST_F(UberUIBrowserTest, EnableMdHistoryHidesHistory) {
- base::CommandLine::ForCurrentProcess()->AppendSwitch(
- ::switches::kEnableMaterialDesignHistory);
ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIUberFrameURL));
SelectTab();
EXPECT_TRUE(GetJsBool("$('history').hidden"));

Powered by Google App Engine
This is Rietveld 408576698