OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 "content/renderer/gpu/queue_message_swap_promise.h" | 5 #include "content/renderer/gpu/queue_message_swap_promise.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/memory/scoped_vector.h" | 9 #include "base/memory/scoped_vector.h" |
10 #include "cc/output/swap_promise.h" | 10 #include "cc/output/swap_promise.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 using RenderWidget::QueueMessageImpl; | 24 using RenderWidget::QueueMessageImpl; |
25 | 25 |
26 private: | 26 private: |
27 ~TestRenderWidget() override {} | 27 ~TestRenderWidget() override {} |
28 | 28 |
29 DISALLOW_COPY_AND_ASSIGN(TestRenderWidget); | 29 DISALLOW_COPY_AND_ASSIGN(TestRenderWidget); |
30 }; | 30 }; |
31 | 31 |
32 class TestSyncMessageFilter : public IPC::SyncMessageFilter { | 32 class TestSyncMessageFilter : public IPC::SyncMessageFilter { |
33 public: | 33 public: |
34 TestSyncMessageFilter() : IPC::SyncMessageFilter(NULL) {} | 34 TestSyncMessageFilter() : IPC::SyncMessageFilter(NULL, false) {} |
35 | 35 |
36 bool Send(IPC::Message* message) override { | 36 bool Send(IPC::Message* message) override { |
37 messages_.push_back(message); | 37 messages_.push_back(message); |
38 return true; | 38 return true; |
39 } | 39 } |
40 | 40 |
41 ScopedVector<IPC::Message>& messages() { return messages_; } | 41 ScopedVector<IPC::Message>& messages() { return messages_; } |
42 | 42 |
43 private: | 43 private: |
44 ~TestSyncMessageFilter() override {} | 44 ~TestSyncMessageFilter() override {} |
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
314 TEST_F(QueueMessageSwapPromiseTest, VisualStateSwapPromiseDidNotSwapSwapFails) { | 314 TEST_F(QueueMessageSwapPromiseTest, VisualStateSwapPromiseDidNotSwapSwapFails) { |
315 VisualStateSwapPromiseDidNotSwap(cc::SwapPromise::SWAP_FAILS); | 315 VisualStateSwapPromiseDidNotSwap(cc::SwapPromise::SWAP_FAILS); |
316 } | 316 } |
317 | 317 |
318 TEST_F(QueueMessageSwapPromiseTest, | 318 TEST_F(QueueMessageSwapPromiseTest, |
319 VisualStateSwapPromiseDidNotSwapActivationFails) { | 319 VisualStateSwapPromiseDidNotSwapActivationFails) { |
320 VisualStateSwapPromiseDidNotSwap(cc::SwapPromise::ACTIVATION_FAILS); | 320 VisualStateSwapPromiseDidNotSwap(cc::SwapPromise::ACTIVATION_FAILS); |
321 } | 321 } |
322 | 322 |
323 } // namespace content | 323 } // namespace content |
OLD | NEW |