OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/path_service.h" | 8 #include "base/path_service.h" |
9 #include "base/stringprintf.h" | 9 #include "base/stringprintf.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 | 424 |
425 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { | 425 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { |
426 #if defined(ENABLE_SAFE_BROWSING) | 426 #if defined(ENABLE_SAFE_BROWSING) |
427 SafeBrowsingService::RegisterFactory(safe_browsing_factory_.get()); | 427 SafeBrowsingService::RegisterFactory(safe_browsing_factory_.get()); |
428 #endif | 428 #endif |
429 } | 429 } |
430 | 430 |
431 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { | 431 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { |
432 command_line->AppendSwitchASCII(switches::kPrerenderMode, | 432 command_line->AppendSwitchASCII(switches::kPrerenderMode, |
433 switches::kPrerenderModeSwitchValueEnabled); | 433 switches::kPrerenderModeSwitchValueEnabled); |
434 // This is needed to enable click-to-play without triggering a DCHECK. | |
435 // It does not actually enable click-to-play. | |
436 command_line->AppendSwitchASCII(switches::kEnableClickToPlay, ""); | |
437 #if defined(OS_MACOSX) | 434 #if defined(OS_MACOSX) |
438 // The plugins directory isn't read by default on the Mac, so it needs to be | 435 // The plugins directory isn't read by default on the Mac, so it needs to be |
439 // explicitly registered. | 436 // explicitly registered. |
440 FilePath app_dir; | 437 FilePath app_dir; |
441 PathService::Get(chrome::DIR_APP, &app_dir); | 438 PathService::Get(chrome::DIR_APP, &app_dir); |
442 command_line->AppendSwitchPath( | 439 command_line->AppendSwitchPath( |
443 switches::kExtraPluginDir, | 440 switches::kExtraPluginDir, |
444 app_dir.Append(FILE_PATH_LITERAL("plugins"))); | 441 app_dir.Append(FILE_PATH_LITERAL("plugins"))); |
445 #endif | 442 #endif |
446 } | 443 } |
(...skipping 1409 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1856 IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, DISABLED_PrerenderSessionStorage) { | 1853 IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, DISABLED_PrerenderSessionStorage) { |
1857 set_loader_path("files/prerender/prerender_loader_with_session_storage.html"); | 1854 set_loader_path("files/prerender/prerender_loader_with_session_storage.html"); |
1858 PrerenderTestURL(GetCrossDomainTestUrl("files/prerender/prerender_page.html"), | 1855 PrerenderTestURL(GetCrossDomainTestUrl("files/prerender/prerender_page.html"), |
1859 FINAL_STATUS_USED, | 1856 FINAL_STATUS_USED, |
1860 1); | 1857 1); |
1861 NavigateToDestURL(); | 1858 NavigateToDestURL(); |
1862 GoBackToPageBeforePrerender(browser()); | 1859 GoBackToPageBeforePrerender(browser()); |
1863 } | 1860 } |
1864 | 1861 |
1865 } // namespace prerender | 1862 } // namespace prerender |
OLD | NEW |