OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #include <memory> | 5 #include <memory> |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "services/service_manager/public/cpp/service_test.h" | 9 #include "services/service_manager/public/cpp/service_test.h" |
10 #include "services/ui/public/cpp/window.h" | 10 #include "services/ui/public/cpp/window.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 // ui::WindowTreeClientDelegate: | 24 // ui::WindowTreeClientDelegate: |
25 void OnEmbed(ui::Window* root) override {} | 25 void OnEmbed(ui::Window* root) override {} |
26 void OnEmbedRootDestroyed(ui::Window* root) override {} | 26 void OnEmbedRootDestroyed(ui::Window* root) override {} |
27 void OnLostConnection(ui::WindowTreeClient* client) override {} | 27 void OnLostConnection(ui::WindowTreeClient* client) override {} |
28 void OnPointerEventObserved(const ui::PointerEvent& event, | 28 void OnPointerEventObserved(const ui::PointerEvent& event, |
29 ui::Window* target) override {} | 29 ui::Window* target) override {} |
30 | 30 |
31 DISALLOW_COPY_AND_ASSIGN(WindowTreeClientDelegate); | 31 DISALLOW_COPY_AND_ASSIGN(WindowTreeClientDelegate); |
32 }; | 32 }; |
33 | 33 |
34 class WindowManagerTest : public shell::test::ServiceTest { | 34 class WindowManagerTest : public service_manager::test::ServiceTest { |
35 public: | 35 public: |
36 WindowManagerTest() : shell::test::ServiceTest("exe:mash_unittests") {} | 36 WindowManagerTest() |
| 37 : service_manager::test::ServiceTest("exe:mash_unittests") {} |
37 ~WindowManagerTest() override {} | 38 ~WindowManagerTest() override {} |
38 | 39 |
39 private: | 40 private: |
40 DISALLOW_COPY_AND_ASSIGN(WindowManagerTest); | 41 DISALLOW_COPY_AND_ASSIGN(WindowManagerTest); |
41 }; | 42 }; |
42 | 43 |
43 void OnEmbed(bool success) { | 44 void OnEmbed(bool success) { |
44 ASSERT_TRUE(success); | 45 ASSERT_TRUE(success); |
45 } | 46 } |
46 | 47 |
(...skipping 19 matching lines...) Expand all Loading... |
66 auto tree_client_request = GetProxy(&tree_client); | 67 auto tree_client_request = GetProxy(&tree_client); |
67 child_window->Embed(std::move(tree_client), base::Bind(&OnEmbed)); | 68 child_window->Embed(std::move(tree_client), base::Bind(&OnEmbed)); |
68 std::unique_ptr<ui::WindowTreeClient> child_client(new ui::WindowTreeClient( | 69 std::unique_ptr<ui::WindowTreeClient> child_client(new ui::WindowTreeClient( |
69 &window_tree_delegate, nullptr, std::move(tree_client_request))); | 70 &window_tree_delegate, nullptr, std::move(tree_client_request))); |
70 child_client->WaitForEmbed(); | 71 child_client->WaitForEmbed(); |
71 ASSERT_TRUE(!child_client->GetRoots().empty()); | 72 ASSERT_TRUE(!child_client->GetRoots().empty()); |
72 } | 73 } |
73 | 74 |
74 } // namespace mus | 75 } // namespace mus |
75 } // namespace ash | 76 } // namespace ash |
OLD | NEW |