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 #ifndef CONTENT_PUBLIC_TEST_TEST_UTILS_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_TEST_UTILS_H_ |
6 #define CONTENT_PUBLIC_TEST_TEST_UTILS_H_ | 6 #define CONTENT_PUBLIC_TEST_TEST_UTILS_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 return source_; | 167 return source_; |
168 } | 168 } |
169 | 169 |
170 const NotificationDetails& details() const { | 170 const NotificationDetails& details() const { |
171 return details_; | 171 return details_; |
172 } | 172 } |
173 | 173 |
174 // NotificationObserver: | 174 // NotificationObserver: |
175 virtual void Observe(int type, | 175 virtual void Observe(int type, |
176 const NotificationSource& source, | 176 const NotificationSource& source, |
177 const NotificationDetails& details) OVERRIDE; | 177 const NotificationDetails& details) override; |
178 | 178 |
179 private: | 179 private: |
180 bool seen_; | 180 bool seen_; |
181 bool running_; | 181 bool running_; |
182 NotificationRegistrar registrar_; | 182 NotificationRegistrar registrar_; |
183 | 183 |
184 ConditionTestCallback callback_; | 184 ConditionTestCallback callback_; |
185 | 185 |
186 NotificationSource source_; | 186 NotificationSource source_; |
187 NotificationDetails details_; | 187 NotificationDetails details_; |
(...skipping 13 matching lines...) Expand all Loading... |
201 // Note: this class should be declared after the TestBrowserThreadBundle and | 201 // Note: this class should be declared after the TestBrowserThreadBundle and |
202 // ShadowingAtExitManager (if it exists) as it will need to be run before they | 202 // ShadowingAtExitManager (if it exists) as it will need to be run before they |
203 // are torn down. | 203 // are torn down. |
204 class InProcessUtilityThreadHelper : public BrowserChildProcessObserver { | 204 class InProcessUtilityThreadHelper : public BrowserChildProcessObserver { |
205 public: | 205 public: |
206 InProcessUtilityThreadHelper(); | 206 InProcessUtilityThreadHelper(); |
207 virtual ~InProcessUtilityThreadHelper(); | 207 virtual ~InProcessUtilityThreadHelper(); |
208 | 208 |
209 private: | 209 private: |
210 virtual void BrowserChildProcessHostConnected( | 210 virtual void BrowserChildProcessHostConnected( |
211 const ChildProcessData& data) OVERRIDE; | 211 const ChildProcessData& data) override; |
212 virtual void BrowserChildProcessHostDisconnected( | 212 virtual void BrowserChildProcessHostDisconnected( |
213 const ChildProcessData& data) OVERRIDE; | 213 const ChildProcessData& data) override; |
214 | 214 |
215 int child_thread_count_; | 215 int child_thread_count_; |
216 scoped_refptr<MessageLoopRunner> runner_; | 216 scoped_refptr<MessageLoopRunner> runner_; |
217 | 217 |
218 DISALLOW_COPY_AND_ASSIGN(InProcessUtilityThreadHelper); | 218 DISALLOW_COPY_AND_ASSIGN(InProcessUtilityThreadHelper); |
219 }; | 219 }; |
220 | 220 |
221 } // namespace content | 221 } // namespace content |
222 | 222 |
223 #endif // CONTENT_PUBLIC_TEST_TEST_UTILS_H_ | 223 #endif // CONTENT_PUBLIC_TEST_TEST_UTILS_H_ |
OLD | NEW |