OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_UI_UI_TEST_H_ | 5 #ifndef CHROME_TEST_UI_UI_TEST_H_ |
6 #define CHROME_TEST_UI_UI_TEST_H_ | 6 #define CHROME_TEST_UI_UI_TEST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 // This file provides a common base for running UI unit tests, which operate | 9 // This file provides a common base for running UI unit tests, which operate |
10 // the entire browser application in a separate process for holistic | 10 // the entire browser application in a separate process for holistic |
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
360 base::Time test_start_time_; | 360 base::Time test_start_time_; |
361 }; | 361 }; |
362 | 362 |
363 class UITest : public UITestBase, public PlatformTest { | 363 class UITest : public UITestBase, public PlatformTest { |
364 protected: | 364 protected: |
365 UITest() {} | 365 UITest() {} |
366 explicit UITest(MessageLoop::Type msg_loop_type) | 366 explicit UITest(MessageLoop::Type msg_loop_type) |
367 : UITestBase(), PlatformTest(), message_loop_(msg_loop_type) { | 367 : UITestBase(), PlatformTest(), message_loop_(msg_loop_type) { |
368 } | 368 } |
369 | 369 |
370 virtual void SetUp(); | 370 virtual void SetUp() OVERRIDE; |
371 virtual void TearDown(); | 371 virtual void TearDown() OVERRIDE; |
372 | 372 |
373 virtual ProxyLauncher* CreateProxyLauncher(); | 373 virtual ProxyLauncher* CreateProxyLauncher() OVERRIDE; |
374 | 374 |
375 // Count the number of active browser processes launched by this test. | 375 // Count the number of active browser processes launched by this test. |
376 // The count includes browser sub-processes. | 376 // The count includes browser sub-processes. |
377 bool GetBrowserProcessCount(int* count) WARN_UNUSED_RESULT; | 377 bool GetBrowserProcessCount(int* count) WARN_UNUSED_RESULT; |
378 | 378 |
379 // Returns a copy of local state preferences. The caller is responsible for | 379 // Returns a copy of local state preferences. The caller is responsible for |
380 // deleting the returned object. Returns NULL if there is an error. | 380 // deleting the returned object. Returns NULL if there is an error. |
381 base::DictionaryValue* GetLocalState(); | 381 base::DictionaryValue* GetLocalState(); |
382 | 382 |
383 // Returns a copy of the default profile preferences. The caller is | 383 // Returns a copy of the default profile preferences. The caller is |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
483 #ifdef UNIT_TEST | 483 #ifdef UNIT_TEST |
484 std::ostream& operator<<(std::ostream& out, const std::wstring& wstr); | 484 std::ostream& operator<<(std::ostream& out, const std::wstring& wstr); |
485 | 485 |
486 template<typename T> | 486 template<typename T> |
487 std::ostream& operator<<(std::ostream& out, const ::scoped_ptr<T>& ptr) { | 487 std::ostream& operator<<(std::ostream& out, const ::scoped_ptr<T>& ptr) { |
488 return out << ptr.get(); | 488 return out << ptr.get(); |
489 } | 489 } |
490 #endif // UNIT_TEST | 490 #endif // UNIT_TEST |
491 | 491 |
492 #endif // CHROME_TEST_UI_UI_TEST_H_ | 492 #endif // CHROME_TEST_UI_UI_TEST_H_ |
OLD | NEW |