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 "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
8 #include "base/strings/stringprintf.h" | 8 #include "base/strings/stringprintf.h" |
9 #include "base/test/test_timeouts.h" | 9 #include "base/test/test_timeouts.h" |
10 #include "components/view_manager/public/cpp/tests/view_manager_test_base.h" | 10 #include "components/view_manager/public/cpp/tests/view_manager_test_base.h" |
(...skipping 25 matching lines...) Expand all Loading... |
36 bool EnableOOPIFs() { | 36 bool EnableOOPIFs() { |
37 return base::CommandLine::ForCurrentProcess()->HasSwitch(kOOPIF); | 37 return base::CommandLine::ForCurrentProcess()->HasSwitch(kOOPIF); |
38 } | 38 } |
39 | 39 |
40 class TestFrameTreeServer : public mandoline::FrameTreeServer { | 40 class TestFrameTreeServer : public mandoline::FrameTreeServer { |
41 public: | 41 public: |
42 TestFrameTreeServer() {} | 42 TestFrameTreeServer() {} |
43 ~TestFrameTreeServer() override {} | 43 ~TestFrameTreeServer() override {} |
44 | 44 |
45 // mandoline::FrameTreeServer: | 45 // mandoline::FrameTreeServer: |
46 void PostMessageEventToFrame(uint32_t frame_id, | 46 void PostMessageEventToFrame(uint32_t source_frame_id, |
47 mandoline::MessageEventPtr event) override {} | 47 uint32_t target_frame_id, |
| 48 mandoline::HTMLMessageEventPtr event) override {} |
48 void LoadingStarted(uint32_t frame_id) override {} | 49 void LoadingStarted(uint32_t frame_id) override {} |
49 void LoadingStopped(uint32_t frame_id) override {} | 50 void LoadingStopped(uint32_t frame_id) override {} |
50 void ProgressChanged(uint32_t frame_id, double progress) override {} | 51 void ProgressChanged(uint32_t frame_id, double progress) override {} |
51 void SetClientProperty(uint32_t frame_id, | 52 void SetClientProperty(uint32_t frame_id, |
52 const mojo::String& name, | 53 const mojo::String& name, |
53 mojo::Array<uint8_t> value) override {} | 54 mojo::Array<uint8_t> value) override {} |
54 void OnCreatedFrame(uint32_t parent_id, | 55 void OnCreatedFrame(uint32_t parent_id, |
55 uint32_t frame_id, | 56 uint32_t frame_id, |
56 mojo::Map<mojo::String, mojo::Array<uint8_t>> | 57 mojo::Map<mojo::String, mojo::Array<uint8_t>> |
57 client_properties) override {} | 58 client_properties) override {} |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 EXPECT_TRUE(QuitRunLoop()); | 118 EXPECT_TRUE(QuitRunLoop()); |
118 }); | 119 }); |
119 ASSERT_TRUE(DoRunLoopWithTimeout()); | 120 ASSERT_TRUE(DoRunLoopWithTimeout()); |
120 | 121 |
121 EXPECT_TRUE(AxTreeContainsText(ax_tree, "Hello ")); | 122 EXPECT_TRUE(AxTreeContainsText(ax_tree, "Hello ")); |
122 EXPECT_TRUE(AxTreeContainsText(ax_tree, "World!")); | 123 EXPECT_TRUE(AxTreeContainsText(ax_tree, "World!")); |
123 EXPECT_FALSE(AxTreeContainsText(ax_tree, "foo")); | 124 EXPECT_FALSE(AxTreeContainsText(ax_tree, "foo")); |
124 } | 125 } |
125 | 126 |
126 } // namespace mojo | 127 } // namespace mojo |
OLD | NEW |