| 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 "base/base_paths.h" | 7 #include "base/base_paths.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/debug/stack_trace.h" | 9 #include "base/debug/stack_trace.h" |
| 10 #include "base/i18n/icu_util.h" | 10 #include "base/i18n/icu_util.h" |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 RegisterPathProvider(); | 73 RegisterPathProvider(); |
| 74 ui::RegisterPathProvider(); | 74 ui::RegisterPathProvider(); |
| 75 RegisterInProcessThreads(); | 75 RegisterInProcessThreads(); |
| 76 | 76 |
| 77 InitializeMojo(); | 77 InitializeMojo(); |
| 78 #endif | 78 #endif |
| 79 | 79 |
| 80 ContentTestSuiteBase::Initialize(); | 80 ContentTestSuiteBase::Initialize(); |
| 81 } | 81 } |
| 82 | 82 |
| 83 virtual void Shutdown() OVERRIDE { | |
| 84 ContentTestSuiteBase::Shutdown(); | |
| 85 | |
| 86 #if defined(OS_ANDROID) | |
| 87 ShutdownMojo(); | |
| 88 #endif | |
| 89 } | |
| 90 | |
| 91 #if defined(OS_ANDROID) | 83 #if defined(OS_ANDROID) |
| 92 scoped_ptr<ShellContentClient> content_client_; | 84 scoped_ptr<ShellContentClient> content_client_; |
| 93 scoped_ptr<ShellContentBrowserClient> browser_content_client_; | 85 scoped_ptr<ShellContentBrowserClient> browser_content_client_; |
| 94 #endif | 86 #endif |
| 95 | 87 |
| 96 DISALLOW_COPY_AND_ASSIGN(ContentBrowserTestSuite); | 88 DISALLOW_COPY_AND_ASSIGN(ContentBrowserTestSuite); |
| 97 }; | 89 }; |
| 98 | 90 |
| 99 class ContentTestLauncherDelegate : public TestLauncherDelegate { | 91 class ContentTestLauncherDelegate : public TestLauncherDelegate { |
| 100 public: | 92 public: |
| (...skipping 22 matching lines...) Expand all Loading... |
| 123 DISALLOW_COPY_AND_ASSIGN(ContentTestLauncherDelegate); | 115 DISALLOW_COPY_AND_ASSIGN(ContentTestLauncherDelegate); |
| 124 }; | 116 }; |
| 125 | 117 |
| 126 } // namespace content | 118 } // namespace content |
| 127 | 119 |
| 128 int main(int argc, char** argv) { | 120 int main(int argc, char** argv) { |
| 129 int default_jobs = std::max(1, base::SysInfo::NumberOfProcessors() / 2); | 121 int default_jobs = std::max(1, base::SysInfo::NumberOfProcessors() / 2); |
| 130 content::ContentTestLauncherDelegate launcher_delegate; | 122 content::ContentTestLauncherDelegate launcher_delegate; |
| 131 return LaunchTests(&launcher_delegate, default_jobs, argc, argv); | 123 return LaunchTests(&launcher_delegate, default_jobs, argc, argv); |
| 132 } | 124 } |
| OLD | NEW |