| 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 "content/public/test/test_launcher.h" | 5 #include "content/public/test/test_launcher.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 495 return launcher_delegate->RunTestSuite(argc, argv); | 495 return launcher_delegate->RunTestSuite(argc, argv); |
| 496 } | 496 } |
| 497 | 497 |
| 498 #if !defined(OS_ANDROID) | 498 #if !defined(OS_ANDROID) |
| 499 if (command_line->HasSwitch(switches::kProcessType) || | 499 if (command_line->HasSwitch(switches::kProcessType) || |
| 500 command_line->HasSwitch(kLaunchAsBrowser)) { | 500 command_line->HasSwitch(kLaunchAsBrowser)) { |
| 501 return ContentMain(params); | 501 return ContentMain(params); |
| 502 } | 502 } |
| 503 #endif | 503 #endif |
| 504 | 504 |
| 505 #if !defined(OS_WIN) |
| 506 // This is done earlier on Windows. |
| 505 base::AtExitManager at_exit; | 507 base::AtExitManager at_exit; |
| 508 #endif |
| 506 testing::InitGoogleTest(&argc, argv); | 509 testing::InitGoogleTest(&argc, argv); |
| 507 TestTimeouts::Initialize(); | 510 TestTimeouts::Initialize(); |
| 508 | 511 |
| 509 fprintf(stdout, | 512 fprintf(stdout, |
| 510 "IMPORTANT DEBUGGING NOTE: each test is run inside its own process.\n" | 513 "IMPORTANT DEBUGGING NOTE: each test is run inside its own process.\n" |
| 511 "For debugging a test inside a debugger, use the\n" | 514 "For debugging a test inside a debugger, use the\n" |
| 512 "--gtest_filter=<your_test_name> flag along with either\n" | 515 "--gtest_filter=<your_test_name> flag along with either\n" |
| 513 "--single_process (to run the test in one launcher/browser process) or\n" | 516 "--single_process (to run the test in one launcher/browser process) or\n" |
| 514 "--single-process (to do the above, and also run Chrome in single-" | 517 "--single-process (to do the above, and also run Chrome in single-" |
| 515 "process mode).\n"); | 518 "process mode).\n"); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 526 | 529 |
| 527 TestLauncherDelegate* GetCurrentTestLauncherDelegate() { | 530 TestLauncherDelegate* GetCurrentTestLauncherDelegate() { |
| 528 return g_launcher_delegate; | 531 return g_launcher_delegate; |
| 529 } | 532 } |
| 530 | 533 |
| 531 ContentMainParams* GetContentMainParams() { | 534 ContentMainParams* GetContentMainParams() { |
| 532 return g_params; | 535 return g_params; |
| 533 } | 536 } |
| 534 | 537 |
| 535 } // namespace content | 538 } // namespace content |
| OLD | NEW |