OLD | NEW |
1 // Copyright (c) 2006-2010 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_frame/test/reliability/reliability_test_suite.h" | 5 #include "chrome_frame/test/reliability/reliability_test_suite.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "chrome/common/chrome_paths.h" | 8 #include "chrome/common/chrome_paths.h" |
9 #include "chrome_frame/test/chrome_frame_test_utils.h" | 9 #include "chrome_frame/test/chrome_frame_test_utils.h" |
10 #include "chrome_frame/test_utils.h" | 10 #include "chrome_frame/test_utils.h" |
11 #include "chrome_frame/utils.h" | 11 #include "chrome_frame/utils.h" |
12 | 12 |
13 static const char kRegisterDllFlag[] = "register"; | 13 static const char kRegisterDllFlag[] = "register"; |
14 | 14 |
15 int main(int argc, char **argv) { | 15 int main(int argc, char **argv) { |
| 16 ScopedChromeFrameRegistrar::RegisterAndExitProcessIfDirected(); |
16 // We create this slightly early as it is the one who instantiates THE | 17 // We create this slightly early as it is the one who instantiates THE |
17 // AtExitManager which some of the other stuff below relies on. | 18 // AtExitManager which some of the other stuff below relies on. |
18 ReliabilityTestSuite test_suite(argc, argv); | 19 ReliabilityTestSuite test_suite(argc, argv); |
19 | 20 |
20 SetConfigBool(kChromeFrameHeadlessMode, true); | 21 SetConfigBool(kChromeFrameHeadlessMode, true); |
21 base::ProcessHandle crash_service = chrome_frame_test::StartCrashService(); | 22 base::ProcessHandle crash_service = chrome_frame_test::StartCrashService(); |
22 | 23 |
23 int result = -1; | 24 int result = -1; |
24 // If --register is passed, then we need to ensure that Chrome Frame is | 25 // If --register is passed, then we need to ensure that Chrome Frame is |
25 // registered before starting up the reliability tests. | 26 // registered before starting up the reliability tests. |
(...skipping 15 matching lines...) Expand all Loading... |
41 result = test_suite.Run(); | 42 result = test_suite.Run(); |
42 } | 43 } |
43 | 44 |
44 DeleteConfigValue(kChromeFrameHeadlessMode); | 45 DeleteConfigValue(kChromeFrameHeadlessMode); |
45 if (crash_service) | 46 if (crash_service) |
46 base::KillProcess(crash_service, 0, false); | 47 base::KillProcess(crash_service, 0, false); |
47 | 48 |
48 return result; | 49 return result; |
49 } | 50 } |
50 | 51 |
OLD | NEW |