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 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 virtual bool plugin_finder_disabled() const OVERRIDE; | 97 virtual bool plugin_finder_disabled() const OVERRIDE; |
98 | 98 |
99 #if (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) | 99 #if (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) |
100 virtual void StartAutoupdateTimer() OVERRIDE {} | 100 virtual void StartAutoupdateTimer() OVERRIDE {} |
101 #endif | 101 #endif |
102 | 102 |
103 virtual ChromeNetLog* net_log() OVERRIDE; | 103 virtual ChromeNetLog* net_log() OVERRIDE; |
104 virtual prerender::PrerenderTracker* prerender_tracker() OVERRIDE; | 104 virtual prerender::PrerenderTracker* prerender_tracker() OVERRIDE; |
105 virtual ComponentUpdateService* component_updater() OVERRIDE; | 105 virtual ComponentUpdateService* component_updater() OVERRIDE; |
106 virtual CRLSetFetcher* crl_set_fetcher() OVERRIDE; | 106 virtual CRLSetFetcher* crl_set_fetcher() OVERRIDE; |
| 107 virtual chrome::MediaDeviceManager* media_device_manager() OVERRIDE; |
107 | 108 |
108 // Set the local state for tests. Consumer is responsible for cleaning it up | 109 // Set the local state for tests. Consumer is responsible for cleaning it up |
109 // afterwards (using ScopedTestingLocalState, for example). | 110 // afterwards (using ScopedTestingLocalState, for example). |
110 void SetLocalState(PrefService* local_state); | 111 void SetLocalState(PrefService* local_state); |
111 void SetProfileManager(ProfileManager* profile_manager); | 112 void SetProfileManager(ProfileManager* profile_manager); |
112 void SetIOThread(IOThread* io_thread); | 113 void SetIOThread(IOThread* io_thread); |
113 void SetBrowserPolicyConnector(policy::BrowserPolicyConnector* connector); | 114 void SetBrowserPolicyConnector(policy::BrowserPolicyConnector* connector); |
114 void SetSafeBrowsingService(SafeBrowsingService* sb_service); | 115 void SetSafeBrowsingService(SafeBrowsingService* sb_service); |
115 | 116 |
116 private: | 117 private: |
(...skipping 12 matching lines...) Expand all Loading... |
129 scoped_refptr<printing::PrintPreviewTabController> | 130 scoped_refptr<printing::PrintPreviewTabController> |
130 print_preview_tab_controller_; | 131 print_preview_tab_controller_; |
131 scoped_ptr<prerender::PrerenderTracker> prerender_tracker_; | 132 scoped_ptr<prerender::PrerenderTracker> prerender_tracker_; |
132 IOThread* io_thread_; | 133 IOThread* io_thread_; |
133 scoped_refptr<SafeBrowsingService> sb_service_; | 134 scoped_refptr<SafeBrowsingService> sb_service_; |
134 | 135 |
135 DISALLOW_COPY_AND_ASSIGN(TestingBrowserProcess); | 136 DISALLOW_COPY_AND_ASSIGN(TestingBrowserProcess); |
136 }; | 137 }; |
137 | 138 |
138 #endif // CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ | 139 #endif // CHROME_TEST_BASE_TESTING_BROWSER_PROCESS_H_ |
OLD | NEW |