| 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 "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 29 matching lines...) Expand all Loading... |
| 40 command_line->AppendSwitchASCII(switches::kEnableLogging, "stderr"); | 40 command_line->AppendSwitchASCII(switches::kEnableLogging, "stderr"); |
| 41 if (!command_line->HasSwitch(switches::kLoggingLevel)) | 41 if (!command_line->HasSwitch(switches::kLoggingLevel)) |
| 42 command_line->AppendSwitchASCII(switches::kLoggingLevel, "0"); // info | 42 command_line->AppendSwitchASCII(switches::kLoggingLevel, "0"); // info |
| 43 | 43 |
| 44 // Disable safebrowsing autoupdate. | 44 // Disable safebrowsing autoupdate. |
| 45 command_line->AppendSwitch(switches::kSbDisableAutoUpdate); | 45 command_line->AppendSwitch(switches::kSbDisableAutoUpdate); |
| 46 | 46 |
| 47 // Don't install default apps. | 47 // Don't install default apps. |
| 48 command_line->AppendSwitch(switches::kDisableDefaultApps); | 48 command_line->AppendSwitch(switches::kDisableDefaultApps); |
| 49 | 49 |
| 50 #if defined(OS_MACOSX) | |
| 51 // Don't collect GPU info, load GPU blacklist, or schedule a GPU blacklist | 50 // Don't collect GPU info, load GPU blacklist, or schedule a GPU blacklist |
| 52 // auto-update on Mac for now (http://crbug.com/304833). | 51 // auto-update. |
| 53 command_line->AppendSwitch(switches::kSkipGpuDataLoading); | 52 command_line->AppendSwitch(switches::kSkipGpuDataLoading); |
| 54 #endif | |
| 55 | 53 |
| 56 #if defined(USE_AURA) | 54 #if defined(USE_AURA) |
| 57 // Disable window animations under Ash as the animations effect the | 55 // Disable window animations under Ash as the animations effect the |
| 58 // coordinates returned and result in flake. | 56 // coordinates returned and result in flake. |
| 59 command_line->AppendSwitch( | 57 command_line->AppendSwitch( |
| 60 views::corewm::switches::kWindowAnimationsDisabled); | 58 views::corewm::switches::kWindowAnimationsDisabled); |
| 61 #endif | 59 #endif |
| 62 | 60 |
| 63 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_CHROMEOS) | 61 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_CHROMEOS) |
| 64 // Don't use the native password stores on Linux since they may | 62 // Don't use the native password stores on Linux since they may |
| (...skipping 27 matching lines...) Expand all Loading... |
| 92 // Note: we use an environment variable here, because we have to pass the | 90 // Note: we use an environment variable here, because we have to pass the |
| 93 // value to the child process. This is the simplest way to do it. | 91 // value to the child process. This is the simplest way to do it. |
| 94 scoped_ptr<base::Environment> env(base::Environment::Create()); | 92 scoped_ptr<base::Environment> env(base::Environment::Create()); |
| 95 success = success && env->SetVar("XDG_CACHE_HOME", user_data_dir.value()); | 93 success = success && env->SetVar("XDG_CACHE_HOME", user_data_dir.value()); |
| 96 #endif | 94 #endif |
| 97 | 95 |
| 98 return success; | 96 return success; |
| 99 } | 97 } |
| 100 | 98 |
| 101 } // namespace test_launcher_utils | 99 } // namespace test_launcher_utils |
| OLD | NEW |