Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(226)

Side by Side Diff: net/url_request/url_request_unittest.h

Issue 18248: CommandLine API rework (Closed)
Patch Set: fixes Created 11 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « net/url_request/url_request_http_job.cc ('k') | skia/ext/vector_canvas_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #ifndef NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_ 5 #ifndef NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_
6 #define NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_ 6 #define NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_
7 7
8 #include <stdlib.h> 8 #include <stdlib.h>
9 9
10 #include <sstream> 10 #include <sstream>
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 342
343 } 343 }
344 344
345 #if defined(OS_WIN) 345 #if defined(OS_WIN)
346 void LaunchApp(const std::wstring& command_line) { 346 void LaunchApp(const std::wstring& command_line) {
347 ASSERT_TRUE(base::LaunchApp(command_line, false, true, &process_handle_)) << 347 ASSERT_TRUE(base::LaunchApp(command_line, false, true, &process_handle_)) <<
348 "Failed to launch " << command_line; 348 "Failed to launch " << command_line;
349 } 349 }
350 #elif defined(OS_POSIX) 350 #elif defined(OS_POSIX)
351 void LaunchApp(const std::vector<std::string>& command_line) { 351 void LaunchApp(const std::vector<std::string>& command_line) {
352 ASSERT_TRUE(base::LaunchApp(command_line, false, true, &process_handle_)) << 352 base::file_handle_mapping_vector fds_empty;
353 ASSERT_TRUE(base::LaunchApp(command_line, fds_empty, false,
354 &process_handle_)) <<
353 "Failed to launch " << command_line[0] << " ..."; 355 "Failed to launch " << command_line[0] << " ...";
354 } 356 }
355 #endif 357 #endif
356 358
357 virtual bool MakeGETRequest(const std::string& page_name) = 0; 359 virtual bool MakeGETRequest(const std::string& page_name) = 0;
358 360
359 // Verify that the Server is actually started. 361 // Verify that the Server is actually started.
360 // Otherwise tests can fail if they run faster than Python can start. 362 // Otherwise tests can fail if they run faster than Python can start.
361 bool VerifyLaunchApp(const std::string& page_name) { 363 bool VerifyLaunchApp(const std::string& page_name) {
362 int retries = 10; 364 int retries = 10;
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 command_line->push_back("python"); 679 command_line->push_back("python");
678 command_line->push_back(WideToUTF8(testserver_path)); 680 command_line->push_back(WideToUTF8(testserver_path));
679 command_line->push_back(" -f "); 681 command_line->push_back(" -f ");
680 command_line->push_back("--data-dir=" + WideToUTF8(test_data_directory)); 682 command_line->push_back("--data-dir=" + WideToUTF8(test_data_directory));
681 command_line->push_back("--port=" + port_str_); 683 command_line->push_back("--port=" + port_str_);
682 } 684 }
683 #endif 685 #endif
684 }; 686 };
685 687
686 #endif // NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_ 688 #endif // NET_URL_REQUEST_URL_REQUEST_UNITTEST_H_
OLDNEW
« no previous file with comments | « net/url_request/url_request_http_job.cc ('k') | skia/ext/vector_canvas_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698