OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 "cc/base/completion_event.h" | 5 #include "cc/base/completion_event.h" |
6 #include "cc/test/begin_frame_args_test.h" | 6 #include "cc/test/begin_frame_args_test.h" |
7 #include "cc/test/fake_content_layer_client.h" | 7 #include "cc/test/fake_content_layer_client.h" |
8 #include "cc/test/fake_external_begin_frame_source.h" | 8 #include "cc/test/fake_external_begin_frame_source.h" |
9 #include "cc/test/fake_picture_layer.h" | 9 #include "cc/test/fake_picture_layer.h" |
10 #include "cc/test/layer_tree_test.h" | 10 #include "cc/test/layer_tree_test.h" |
11 #include "cc/test/skia_common.h" | 11 #include "cc/test/skia_common.h" |
12 #include "cc/test/test_compositor_frame_sink.h" | 12 #include "cc/test/test_compositor_frame_sink.h" |
13 #include "cc/trees/layer_tree_impl.h" | 13 #include "cc/trees/layer_tree_impl.h" |
14 | 14 |
15 namespace cc { | 15 namespace cc { |
16 namespace { | 16 namespace { |
17 | 17 |
18 class LayerTreeHostCheckerImagingTest : public LayerTreeTest { | 18 class LayerTreeHostCheckerImagingTest : public LayerTreeTest { |
19 public: | 19 public: |
20 void BeginTest() override { PostSetNeedsCommitToMainThread(); } | 20 void BeginTest() override { PostSetNeedsCommitToMainThread(); } |
21 void AfterTest() override {} | 21 void AfterTest() override {} |
22 | 22 |
23 void InitializeSettings(LayerTreeSettings* settings) override { | 23 void InitializeSettings(LayerTreeSettings* settings) override { |
24 settings->image_decode_tasks_enabled = true; | |
25 settings->enable_checker_imaging = true; | 24 settings->enable_checker_imaging = true; |
26 } | 25 } |
27 | 26 |
28 void SetupTree() override { | 27 void SetupTree() override { |
29 // Set up a content client which creates the following tiling, x denoting | 28 // Set up a content client which creates the following tiling, x denoting |
30 // the image to checker: | 29 // the image to checker: |
31 // |---|---|---|---| | 30 // |---|---|---|---| |
32 // | x | x | | | | 31 // | x | x | | | |
33 // |---|---|---|---| | 32 // |---|---|---|---| |
34 // | x | x | | | | 33 // | x | x | | | |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 | 186 |
188 int num_of_activations_ = 0; | 187 int num_of_activations_ = 0; |
189 int num_of_commits_ = 0; | 188 int num_of_commits_ = 0; |
190 int num_of_impl_side_invalidations_ = 0; | 189 int num_of_impl_side_invalidations_ = 0; |
191 }; | 190 }; |
192 | 191 |
193 SINGLE_AND_MULTI_THREAD_TEST_F(LayerTreeHostCheckerImagingTestImplSideTree); | 192 SINGLE_AND_MULTI_THREAD_TEST_F(LayerTreeHostCheckerImagingTestImplSideTree); |
194 | 193 |
195 } // namespace | 194 } // namespace |
196 } // namespace cc | 195 } // namespace cc |
OLD | NEW |