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 "chrome/test/base/test_launcher_utils.h" | 5 #include "chrome/test/base/test_launcher_utils.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/environment.h" | 8 #include "base/environment.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 if (!command_line->HasSwitch(switches::kPasswordStore)) | 46 if (!command_line->HasSwitch(switches::kPasswordStore)) |
47 command_line->AppendSwitchASCII(switches::kPasswordStore, "basic"); | 47 command_line->AppendSwitchASCII(switches::kPasswordStore, "basic"); |
48 #endif | 48 #endif |
49 | 49 |
50 #if defined(OS_MACOSX) | 50 #if defined(OS_MACOSX) |
51 // Use mock keychain on mac to prevent blocking permissions dialogs. | 51 // Use mock keychain on mac to prevent blocking permissions dialogs. |
52 // TODO(sync): Re-enable when mock keyring works with sync integration tests. | 52 // TODO(sync): Re-enable when mock keyring works with sync integration tests. |
53 // See crbug.com/89808. | 53 // See crbug.com/89808. |
54 // command_line->AppendSwitch(switches::kUseMockKeychain); | 54 // command_line->AppendSwitch(switches::kUseMockKeychain); |
55 #endif | 55 #endif |
| 56 |
| 57 // Disable the Instant field trial, which may cause unexpected page loads. |
| 58 command_line->AppendSwitchASCII(switches::kInstantFieldTrial, "disabled"); |
56 } | 59 } |
57 | 60 |
58 bool OverrideUserDataDir(const FilePath& user_data_dir) { | 61 bool OverrideUserDataDir(const FilePath& user_data_dir) { |
59 bool success = true; | 62 bool success = true; |
60 | 63 |
61 // PathService::Override() is the best way to change the user data directory. | 64 // PathService::Override() is the best way to change the user data directory. |
62 // This matches what is done in ChromeMain(). | 65 // This matches what is done in ChromeMain(). |
63 success = PathService::Override(chrome::DIR_USER_DATA, user_data_dir); | 66 success = PathService::Override(chrome::DIR_USER_DATA, user_data_dir); |
64 | 67 |
65 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 68 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
(...skipping 14 matching lines...) Expand all Loading... |
80 const std::string& implementation_name) { | 83 const std::string& implementation_name) { |
81 if (command_line->HasSwitch(switches::kUseGL)) | 84 if (command_line->HasSwitch(switches::kUseGL)) |
82 return false; | 85 return false; |
83 | 86 |
84 command_line->AppendSwitchASCII(switches::kUseGL, implementation_name); | 87 command_line->AppendSwitchASCII(switches::kUseGL, implementation_name); |
85 | 88 |
86 return true; | 89 return true; |
87 } | 90 } |
88 | 91 |
89 } // namespace test_launcher_utils | 92 } // namespace test_launcher_utils |
OLD | NEW |