| Index: cc/trees/layer_tree_host_unittest_record_gpu_histogram.cc
|
| diff --git a/cc/trees/layer_tree_host_unittest_record_gpu_histogram.cc b/cc/trees/layer_tree_host_unittest_record_gpu_histogram.cc
|
| index a9b1993bd2ee4c9a297886b265284d832761c1c2..bb64f2ac81e803374b71c3e1c7c70f8fde32c01b 100644
|
| --- a/cc/trees/layer_tree_host_unittest_record_gpu_histogram.cc
|
| +++ b/cc/trees/layer_tree_host_unittest_record_gpu_histogram.cc
|
| @@ -2,6 +2,7 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| +#include "cc/animation/animation_host.h"
|
| #include "cc/test/fake_layer_tree_host.h"
|
| #include "cc/test/fake_layer_tree_host_client.h"
|
| #include "cc/test/test_task_graph_runner.h"
|
| @@ -15,9 +16,10 @@ TEST(LayerTreeHostRecordGpuHistogramTest, SingleThreaded) {
|
| FakeLayerTreeHostClient host_client;
|
| TestTaskGraphRunner task_graph_runner;
|
| LayerTreeSettings settings;
|
| - std::unique_ptr<FakeLayerTreeHost> host =
|
| - FakeLayerTreeHost::Create(&host_client, &task_graph_runner, settings,
|
| - CompositorMode::SINGLE_THREADED);
|
| + auto animation_host = AnimationHost::CreateForTesting(ThreadInstance::MAIN);
|
| + std::unique_ptr<FakeLayerTreeHost> host = FakeLayerTreeHost::Create(
|
| + &host_client, &task_graph_runner, animation_host.get(), settings,
|
| + CompositorMode::SINGLE_THREADED);
|
| host->RecordGpuRasterizationHistogram();
|
| EXPECT_FALSE(host->gpu_rasterization_histogram_recorded());
|
| }
|
| @@ -26,8 +28,10 @@ TEST(LayerTreeHostRecordGpuHistogramTest, Threaded) {
|
| FakeLayerTreeHostClient host_client;
|
| TestTaskGraphRunner task_graph_runner;
|
| LayerTreeSettings settings;
|
| + auto animation_host = AnimationHost::CreateForTesting(ThreadInstance::MAIN);
|
| std::unique_ptr<FakeLayerTreeHost> host = FakeLayerTreeHost::Create(
|
| - &host_client, &task_graph_runner, settings, CompositorMode::THREADED);
|
| + &host_client, &task_graph_runner, animation_host.get(), settings,
|
| + CompositorMode::THREADED);
|
| host->RecordGpuRasterizationHistogram();
|
| EXPECT_TRUE(host->gpu_rasterization_histogram_recorded());
|
| }
|
|
|