OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/shell/browser/shell_browser_main.h" | 5 #include "content/shell/browser/shell_browser_main.h" |
6 | 6 |
7 #include <iostream> | 7 #include <iostream> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 main_runner->Shutdown(); | 144 main_runner->Shutdown(); |
145 return 0; | 145 return 0; |
146 } | 146 } |
147 | 147 |
148 if (layout_test_mode) { | 148 if (layout_test_mode) { |
149 content::WebKitTestController test_controller; | 149 content::WebKitTestController test_controller; |
150 { | 150 { |
151 // We're outside of the message loop here, and this is a test. | 151 // We're outside of the message loop here, and this is a test. |
152 base::ThreadRestrictions::ScopedAllowIO allow_io; | 152 base::ThreadRestrictions::ScopedAllowIO allow_io; |
153 base::FilePath temp_path; | 153 base::FilePath temp_path; |
154 file_util::GetTempDir(&temp_path); | 154 base::GetTempDir(&temp_path); |
155 test_controller.SetTempPath(temp_path); | 155 test_controller.SetTempPath(temp_path); |
156 } | 156 } |
157 std::string test_string; | 157 std::string test_string; |
158 CommandLine::StringVector args = | 158 CommandLine::StringVector args = |
159 CommandLine::ForCurrentProcess()->GetArgs(); | 159 CommandLine::ForCurrentProcess()->GetArgs(); |
160 size_t command_line_position = 0; | 160 size_t command_line_position = 0; |
161 bool ran_at_least_once = false; | 161 bool ran_at_least_once = false; |
162 | 162 |
163 std::cout << "#READY\n"; | 163 std::cout << "#READY\n"; |
164 std::cout.flush(); | 164 std::cout.flush(); |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 | 215 |
216 #if !defined(OS_ANDROID) | 216 #if !defined(OS_ANDROID) |
217 if (!layout_test_mode) | 217 if (!layout_test_mode) |
218 exit_code = main_runner->Run(); | 218 exit_code = main_runner->Run(); |
219 | 219 |
220 main_runner->Shutdown(); | 220 main_runner->Shutdown(); |
221 #endif | 221 #endif |
222 | 222 |
223 return exit_code; | 223 return exit_code; |
224 } | 224 } |
OLD | NEW |