| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ | 5 #ifndef CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ |
| 6 #define CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ | 6 #define CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 service_manager::BackgroundServiceManager* background_service_manager() { | 60 service_manager::BackgroundServiceManager* background_service_manager() { |
| 61 return background_service_manager_.get(); | 61 return background_service_manager_.get(); |
| 62 } | 62 } |
| 63 | 63 |
| 64 // Initializes the Mojo environment, and IPC thread. | 64 // Initializes the Mojo environment, and IPC thread. |
| 65 void Init(); | 65 void Init(); |
| 66 | 66 |
| 67 // Initializes the background thread the ServiceManager runs on. | 67 // Initializes the background thread the ServiceManager runs on. |
| 68 service_manager::mojom::ServiceRequest InitBackgroundServiceManager(); | 68 service_manager::mojom::ServiceRequest InitBackgroundServiceManager(); |
| 69 | 69 |
| 70 std::unique_ptr<service_manager::BackgroundServiceManager> |
| 71 CreateBackgroundServiceManager(service_manager::mojom::ServicePtr service); |
| 72 |
| 70 std::unique_ptr<content::TestState> PrepareForTest( | 73 std::unique_ptr<content::TestState> PrepareForTest( |
| 71 base::CommandLine* command_line, | 74 base::CommandLine* command_line, |
| 72 base::TestLauncher::LaunchOptions* test_launch_options, | 75 base::TestLauncher::LaunchOptions* test_launch_options); |
| 73 base::OnceClosure on_process_launched); | |
| 74 | 76 |
| 75 void StartService(const std::string& service_name); | 77 void StartService(const std::string& service_name); |
| 76 | 78 |
| 77 private: | 79 private: |
| 78 class ServiceProcessLauncherDelegateImpl; | 80 class ServiceProcessLauncherDelegateImpl; |
| 79 | 81 |
| 80 const Config config_; | 82 const Config config_; |
| 81 | 83 |
| 82 std::unique_ptr<ServiceProcessLauncherDelegateImpl> | 84 std::unique_ptr<ServiceProcessLauncherDelegateImpl> |
| 83 service_process_launcher_delegate_; | 85 service_process_launcher_delegate_; |
| 84 std::unique_ptr<service_manager::BackgroundServiceManager> | 86 std::unique_ptr<service_manager::BackgroundServiceManager> |
| 85 background_service_manager_; | 87 background_service_manager_; |
| 86 | 88 |
| 87 std::unique_ptr<base::Thread> ipc_thread_; | 89 std::unique_ptr<base::Thread> ipc_thread_; |
| 88 std::unique_ptr<mojo::edk::ScopedIPCSupport> ipc_support_; | 90 std::unique_ptr<mojo::edk::ScopedIPCSupport> ipc_support_; |
| 89 | 91 |
| 90 std::unique_ptr<base::Value> catalog_contents_; | 92 std::unique_ptr<base::Value> catalog_contents_; |
| 91 | 93 |
| 92 DISALLOW_COPY_AND_ASSIGN(MojoTestConnector); | 94 DISALLOW_COPY_AND_ASSIGN(MojoTestConnector); |
| 93 }; | 95 }; |
| 94 | 96 |
| 95 #endif // CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ | 97 #endif // CHROME_TEST_BASE_MOJO_TEST_CONNECTOR_H_ |
| OLD | NEW |