| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/in_process_browser_test.h" | 5 #include "chrome/test/in_process_browser_test.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/file_path.h" | 8 #include "base/file_path.h" |
| 9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 command_line->AppendSwitchWithValue(switches::kUserDataDir, | 131 command_line->AppendSwitchWithValue(switches::kUserDataDir, |
| 132 user_data_dir.ToWStringHack()); | 132 user_data_dir.ToWStringHack()); |
| 133 | 133 |
| 134 // For some reason the sandbox wasn't happy running in test mode. These | 134 // For some reason the sandbox wasn't happy running in test mode. These |
| 135 // tests aren't intended to test the sandbox, so we turn it off. | 135 // tests aren't intended to test the sandbox, so we turn it off. |
| 136 command_line->AppendSwitch(switches::kNoSandbox); | 136 command_line->AppendSwitch(switches::kNoSandbox); |
| 137 | 137 |
| 138 // Don't show the first run ui. | 138 // Don't show the first run ui. |
| 139 command_line->AppendSwitch(switches::kNoFirstRun); | 139 command_line->AppendSwitch(switches::kNoFirstRun); |
| 140 | 140 |
| 141 // TODO(jcivelli): http://crbug.com/44089 We disable the app launcher on new |
| 142 // tab behavior for now until it is the default behavior on |
| 143 // all platforms. |
| 144 command_line->AppendSwitch(switches::kDisableAppsPanel); |
| 145 |
| 141 // This is a Browser test. | 146 // This is a Browser test. |
| 142 command_line->AppendSwitchWithValue(switches::kTestType, | 147 command_line->AppendSwitchWithValue(switches::kTestType, |
| 143 ASCIIToWide(kBrowserTestType)); | 148 ASCIIToWide(kBrowserTestType)); |
| 144 | 149 |
| 145 // Single-process mode is not set in BrowserMain so it needs to be processed | 150 // Single-process mode is not set in BrowserMain so it needs to be processed |
| 146 // explicitly. | 151 // explicitly. |
| 147 original_single_process_ = RenderProcessHost::run_renderer_in_process(); | 152 original_single_process_ = RenderProcessHost::run_renderer_in_process(); |
| 148 if (command_line->HasSwitch(switches::kSingleProcess)) | 153 if (command_line->HasSwitch(switches::kSingleProcess)) |
| 149 RenderProcessHost::set_run_renderer_in_process(true); | 154 RenderProcessHost::set_run_renderer_in_process(true); |
| 150 | 155 |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 | 330 |
| 326 GTEST_NONFATAL_FAILURE_(error_message.c_str()); | 331 GTEST_NONFATAL_FAILURE_(error_message.c_str()); |
| 327 | 332 |
| 328 MessageLoopForUI::current()->Quit(); | 333 MessageLoopForUI::current()->Quit(); |
| 329 } | 334 } |
| 330 | 335 |
| 331 void InProcessBrowserTest::SetInitialTimeoutInMS(int timeout_value) { | 336 void InProcessBrowserTest::SetInitialTimeoutInMS(int timeout_value) { |
| 332 DCHECK_GT(timeout_value, 0); | 337 DCHECK_GT(timeout_value, 0); |
| 333 initial_timeout_ = timeout_value; | 338 initial_timeout_ = timeout_value; |
| 334 } | 339 } |
| OLD | NEW |