OLD | NEW |
| (Empty) |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef SKY_TOOLS_TESTER_TEST_HARNESS_H_ | |
6 #define SKY_TOOLS_TESTER_TEST_HARNESS_H_ | |
7 | |
8 #include "base/memory/weak_ptr.h" | |
9 #include "sky/tools/tester/test_runner.h" | |
10 | |
11 namespace mojo{ | |
12 class View; | |
13 } | |
14 | |
15 namespace sky { | |
16 namespace tester { | |
17 | |
18 class TestHarness : public TestRunnerClient { | |
19 public: | |
20 explicit TestHarness(mojo::View* container); | |
21 virtual ~TestHarness(); | |
22 | |
23 void ScheduleRun(); | |
24 | |
25 private: | |
26 void Run(); | |
27 void OnTestComplete() override; | |
28 | |
29 mojo::View* container_; | |
30 scoped_ptr<TestRunner> test_runner_; | |
31 base::WeakPtrFactory<TestHarness> weak_ptr_factory_; | |
32 | |
33 MOJO_DISALLOW_COPY_AND_ASSIGN(TestHarness); | |
34 }; | |
35 | |
36 } // namespace tester | |
37 } // namespace sky | |
38 | |
39 #endif // SKY_TOOLS_TESTER_TEST_HARNESS_H_ | |
OLD | NEW |