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

Unified Diff: chrome/browser/apps/app_url_redirector_browsertest.cc

Issue 2537503002: [Prerender] Get the prerender mode from Finch field trial. (Closed)
Patch Set: cleanup Created 4 years 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/browser/chrome_browser_field_trials.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/apps/app_url_redirector_browsertest.cc
diff --git a/chrome/browser/apps/app_url_redirector_browsertest.cc b/chrome/browser/apps/app_url_redirector_browsertest.cc
index b4ca00c89eabb49949ee0d657bbf6c0096573225..838d257c500bd63eea1a2529ca72816798a6c068 100644
--- a/chrome/browser/apps/app_url_redirector_browsertest.cc
+++ b/chrome/browser/apps/app_url_redirector_browsertest.cc
@@ -8,6 +8,7 @@
#include "build/build_config.h"
#include "chrome/browser/apps/app_browsertest_util.h"
#include "chrome/browser/chrome_notification_types.h"
+#include "chrome/browser/prerender/prerender_manager.h"
#include "chrome/browser/ui/browser_navigator_params.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/common/chrome_switches.h"
@@ -23,6 +24,7 @@ namespace extensions {
class PlatformAppUrlRedirectorBrowserTest : public PlatformAppBrowserTest {
public:
void SetUpCommandLine(base::CommandLine* command_line) override;
+ void SetUpOnMainThread() override;
protected:
// Performs the following sequence:
@@ -118,8 +120,12 @@ void PlatformAppUrlRedirectorBrowserTest::SetUpCommandLine(
base::CommandLine* command_line) {
PlatformAppBrowserTest::SetUpCommandLine(command_line);
command_line->AppendSwitch(::switches::kDisablePopupBlocking);
- command_line->AppendSwitchASCII(::switches::kPrerenderMode,
- ::switches::kPrerenderModeSwitchValueEnabled);
+}
+
+void PlatformAppUrlRedirectorBrowserTest::SetUpOnMainThread() {
+ PlatformAppBrowserTest::SetUpOnMainThread();
+ prerender::PrerenderManager::SetMode(
+ prerender::PrerenderManager::PRERENDER_MODE_ENABLED);
}
// TODO(sergeygs): Factor out common functionality from TestXyz,
« no previous file with comments | « no previous file | chrome/browser/chrome_browser_field_trials.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698