OLD | NEW |
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 | 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/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/stringprintf.h" | 10 #include "base/stringprintf.h" |
(...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
503 switches::kPrerenderModeSwitchValueEnabled); | 503 switches::kPrerenderModeSwitchValueEnabled); |
504 #if defined(OS_MACOSX) | 504 #if defined(OS_MACOSX) |
505 // The plugins directory isn't read by default on the Mac, so it needs to be | 505 // The plugins directory isn't read by default on the Mac, so it needs to be |
506 // explicitly registered. | 506 // explicitly registered. |
507 FilePath app_dir; | 507 FilePath app_dir; |
508 PathService::Get(chrome::DIR_APP, &app_dir); | 508 PathService::Get(chrome::DIR_APP, &app_dir); |
509 command_line->AppendSwitchPath( | 509 command_line->AppendSwitchPath( |
510 switches::kExtraPluginDir, | 510 switches::kExtraPluginDir, |
511 app_dir.Append(FILE_PATH_LITERAL("plugins"))); | 511 app_dir.Append(FILE_PATH_LITERAL("plugins"))); |
512 #endif | 512 #endif |
| 513 command_line->AppendSwitch(switches::kAlwaysAuthorizePlugins); |
513 } | 514 } |
514 | 515 |
515 virtual void SetUpOnMainThread() OVERRIDE { | 516 virtual void SetUpOnMainThread() OVERRIDE { |
516 current_browser()->profile()->GetPrefs()->SetBoolean( | 517 current_browser()->profile()->GetPrefs()->SetBoolean( |
517 prefs::kPromptForDownload, false); | 518 prefs::kPromptForDownload, false); |
518 IncreasePrerenderMemory(); | 519 IncreasePrerenderMemory(); |
519 ASSERT_TRUE(test_server()->Start()); | 520 ASSERT_TRUE(test_server()->Start()); |
520 } | 521 } |
521 | 522 |
522 // Overload for a single expected final status | 523 // Overload for a single expected final status |
(...skipping 1722 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2245 IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, PrerenderSSLReferrerPolicy) { | 2246 IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, PrerenderSSLReferrerPolicy) { |
2246 set_use_https_src(true); | 2247 set_use_https_src(true); |
2247 set_loader_path("files/prerender/prerender_loader_with_referrer_policy.html"); | 2248 set_loader_path("files/prerender/prerender_loader_with_referrer_policy.html"); |
2248 PrerenderTestURL("files/prerender/prerender_referrer_policy.html", | 2249 PrerenderTestURL("files/prerender/prerender_referrer_policy.html", |
2249 FINAL_STATUS_USED, | 2250 FINAL_STATUS_USED, |
2250 1); | 2251 1); |
2251 NavigateToDestURL(); | 2252 NavigateToDestURL(); |
2252 } | 2253 } |
2253 | 2254 |
2254 } // namespace prerender | 2255 } // namespace prerender |
OLD | NEW |