| 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 // An implementation of BrowserProcess for unit tests that fails for most | 5 // An implementation of BrowserProcess for unit tests that fails for most |
| 6 // services. By preventing creation of services, we reduce dependencies and | 6 // services. By preventing creation of services, we reduce dependencies and |
| 7 // keep the profile clean. Clients of this class must handle the NULL return | 7 // keep the profile clean. Clients of this class must handle the NULL return |
| 8 // value, however. | 8 // value, however. |
| 9 | 9 |
| 10 #ifndef CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ | 10 #ifndef CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 virtual CRLSetFetcher* crl_set_fetcher() OVERRIDE; | 111 virtual CRLSetFetcher* crl_set_fetcher() OVERRIDE; |
| 112 virtual component_updater::PnaclComponentInstaller* | 112 virtual component_updater::PnaclComponentInstaller* |
| 113 pnacl_component_installer() OVERRIDE; | 113 pnacl_component_installer() OVERRIDE; |
| 114 virtual MediaFileSystemRegistry* media_file_system_registry() OVERRIDE; | 114 virtual MediaFileSystemRegistry* media_file_system_registry() OVERRIDE; |
| 115 virtual bool created_local_state() const OVERRIDE; | 115 virtual bool created_local_state() const OVERRIDE; |
| 116 | 116 |
| 117 #if defined(ENABLE_WEBRTC) | 117 #if defined(ENABLE_WEBRTC) |
| 118 virtual WebRtcLogUploader* webrtc_log_uploader() OVERRIDE; | 118 virtual WebRtcLogUploader* webrtc_log_uploader() OVERRIDE; |
| 119 #endif | 119 #endif |
| 120 | 120 |
| 121 virtual NetworkTimeTracker* network_time_tracker() OVERRIDE; | 121 virtual network_time::NetworkTimeTracker* network_time_tracker() OVERRIDE; |
| 122 | 122 |
| 123 // Set the local state for tests. Consumer is responsible for cleaning it up | 123 // Set the local state for tests. Consumer is responsible for cleaning it up |
| 124 // afterwards (using ScopedTestingLocalState, for example). | 124 // afterwards (using ScopedTestingLocalState, for example). |
| 125 void SetLocalState(PrefService* local_state); | 125 void SetLocalState(PrefService* local_state); |
| 126 void SetProfileManager(ProfileManager* profile_manager); | 126 void SetProfileManager(ProfileManager* profile_manager); |
| 127 void SetIOThread(IOThread* io_thread); | 127 void SetIOThread(IOThread* io_thread); |
| 128 void SetBrowserPolicyConnector(policy::BrowserPolicyConnector* connector); | 128 void SetBrowserPolicyConnector(policy::BrowserPolicyConnector* connector); |
| 129 void SetSafeBrowsingService(SafeBrowsingService* sb_service); | 129 void SetSafeBrowsingService(SafeBrowsingService* sb_service); |
| 130 void SetSystemRequestContext(net::URLRequestContextGetter* context_getter); | 130 void SetSystemRequestContext(net::URLRequestContextGetter* context_getter); |
| 131 | 131 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 156 #endif | 156 #endif |
| 157 | 157 |
| 158 scoped_ptr<prerender::PrerenderTracker> prerender_tracker_; | 158 scoped_ptr<prerender::PrerenderTracker> prerender_tracker_; |
| 159 scoped_refptr<SafeBrowsingService> sb_service_; | 159 scoped_refptr<SafeBrowsingService> sb_service_; |
| 160 #endif // !defined(OS_IOS) | 160 #endif // !defined(OS_IOS) |
| 161 | 161 |
| 162 #if !defined(OS_IOS) && !defined(OS_ANDROID) | 162 #if !defined(OS_IOS) && !defined(OS_ANDROID) |
| 163 scoped_ptr<MediaFileSystemRegistry> media_file_system_registry_; | 163 scoped_ptr<MediaFileSystemRegistry> media_file_system_registry_; |
| 164 #endif | 164 #endif |
| 165 | 165 |
| 166 scoped_ptr<NetworkTimeTracker> network_time_tracker_; | 166 scoped_ptr<network_time::NetworkTimeTracker> network_time_tracker_; |
| 167 | 167 |
| 168 // The following objects are not owned by TestingBrowserProcess: | 168 // The following objects are not owned by TestingBrowserProcess: |
| 169 PrefService* local_state_; | 169 PrefService* local_state_; |
| 170 IOThread* io_thread_; | 170 IOThread* io_thread_; |
| 171 net::URLRequestContextGetter* system_request_context_; | 171 net::URLRequestContextGetter* system_request_context_; |
| 172 | 172 |
| 173 scoped_ptr<BrowserProcessPlatformPart> platform_part_; | 173 scoped_ptr<BrowserProcessPlatformPart> platform_part_; |
| 174 | 174 |
| 175 scoped_ptr<extensions::ExtensionsBrowserClient> extensions_browser_client_; | 175 scoped_ptr<extensions::ExtensionsBrowserClient> extensions_browser_client_; |
| 176 | 176 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 194 class TestingBrowserProcessInitializer { | 194 class TestingBrowserProcessInitializer { |
| 195 public: | 195 public: |
| 196 TestingBrowserProcessInitializer(); | 196 TestingBrowserProcessInitializer(); |
| 197 ~TestingBrowserProcessInitializer(); | 197 ~TestingBrowserProcessInitializer(); |
| 198 | 198 |
| 199 private: | 199 private: |
| 200 DISALLOW_COPY_AND_ASSIGN(TestingBrowserProcessInitializer); | 200 DISALLOW_COPY_AND_ASSIGN(TestingBrowserProcessInitializer); |
| 201 }; | 201 }; |
| 202 | 202 |
| 203 #endif // CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ | 203 #endif // CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ |
| OLD | NEW |