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

Side by Side Diff: chrome/browser/prerender/prerender_browsertest.cc

Issue 1141793002: Reland: Fix WebViewPlugin::scheduleAnimation crash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix style nit Created 5 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <deque> 5 #include <deque>
6 #include <vector> 6 #include <vector>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after
1112 void TearDownInProcessBrowserTestFixture() override { 1112 void TearDownInProcessBrowserTestFixture() override {
1113 #if defined(FULL_SAFE_BROWSING) 1113 #if defined(FULL_SAFE_BROWSING)
1114 SafeBrowsingService::RegisterFactory(NULL); 1114 SafeBrowsingService::RegisterFactory(NULL);
1115 #endif 1115 #endif
1116 } 1116 }
1117 1117
1118 void SetUpCommandLine(base::CommandLine* command_line) override { 1118 void SetUpCommandLine(base::CommandLine* command_line) override {
1119 command_line->AppendSwitchASCII(switches::kPrerenderMode, 1119 command_line->AppendSwitchASCII(switches::kPrerenderMode,
1120 switches::kPrerenderModeSwitchValueEnabled); 1120 switches::kPrerenderModeSwitchValueEnabled);
1121 command_line->AppendSwitch(switches::kEnablePepperTesting); 1121 command_line->AppendSwitch(switches::kEnablePepperTesting);
1122 command_line->AppendSwitchASCII(
1123 switches::kOverridePluginPowerSaverForTesting, "ignore-list");
1122 1124
1123 ASSERT_TRUE(ppapi::RegisterPowerSaverTestPlugin(command_line)); 1125 ASSERT_TRUE(ppapi::RegisterPowerSaverTestPlugin(command_line));
1124 } 1126 }
1125 1127
1126 void SetUpOnMainThread() override { 1128 void SetUpOnMainThread() override {
1127 current_browser()->profile()->GetPrefs()->SetBoolean( 1129 current_browser()->profile()->GetPrefs()->SetBoolean(
1128 prefs::kPromptForDownload, false); 1130 prefs::kPromptForDownload, false);
1129 IncreasePrerenderMemory(); 1131 IncreasePrerenderMemory();
1130 if (autostart_test_server_) 1132 if (autostart_test_server_)
1131 ASSERT_TRUE(test_server()->Start()); 1133 ASSERT_TRUE(test_server()->Start());
(...skipping 2940 matching lines...) Expand 10 before | Expand all | Expand 10 after
4072 browser()->tab_strip_model()->GetActiveWebContents(); 4074 browser()->tab_strip_model()->GetActiveWebContents();
4073 bool display_test_result = false; 4075 bool display_test_result = false;
4074 ASSERT_TRUE(content::ExecuteScriptAndExtractBool(web_contents, 4076 ASSERT_TRUE(content::ExecuteScriptAndExtractBool(web_contents,
4075 "DidDisplayReallyPass()", 4077 "DidDisplayReallyPass()",
4076 &display_test_result)); 4078 &display_test_result));
4077 ASSERT_TRUE(display_test_result); 4079 ASSERT_TRUE(display_test_result);
4078 } 4080 }
4079 #endif // !defined(DISABLE_NACL) 4081 #endif // !defined(DISABLE_NACL)
4080 4082
4081 } // namespace prerender 4083 } // namespace prerender
OLDNEW
« no previous file with comments | « chrome/browser/plugins/plugin_power_saver_browsertest.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698