Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(298)

Side by Side Diff: cc/layers/layer_proto_converter_unittest.cc

Issue 2171143002: cc: Get rid of non-delegated rendering in most cc unit tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@killdirecttests
Patch Set: fakeoutputsurface: no-constructor Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/layers/layer_position_constraint_unittest.cc ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "cc/layers/layer_proto_converter.h" 5 #include "cc/layers/layer_proto_converter.h"
6 6
7 #include "cc/layers/empty_content_layer_client.h" 7 #include "cc/layers/empty_content_layer_client.h"
8 #include "cc/layers/heads_up_display_layer.h" 8 #include "cc/layers/heads_up_display_layer.h"
9 #include "cc/layers/layer.h" 9 #include "cc/layers/layer.h"
10 #include "cc/layers/picture_layer.h" 10 #include "cc/layers/picture_layer.h"
11 #include "cc/proto/layer.pb.h" 11 #include "cc/proto/layer.pb.h"
12 #include "cc/test/fake_layer_tree_host.h" 12 #include "cc/test/fake_layer_tree_host.h"
13 #include "cc/test/fake_layer_tree_host_client.h" 13 #include "cc/test/fake_layer_tree_host_client.h"
14 #include "cc/test/test_task_graph_runner.h" 14 #include "cc/test/test_task_graph_runner.h"
15 #include "cc/trees/layer_tree_settings.h" 15 #include "cc/trees/layer_tree_settings.h"
16 #include "testing/gtest/include/gtest/gtest.h" 16 #include "testing/gtest/include/gtest/gtest.h"
17 17
18 namespace cc { 18 namespace cc {
19 namespace { 19 namespace {
20 class LayerProtoConverterTest : public testing::Test { 20 class LayerProtoConverterTest : public testing::Test {
21 public:
22 LayerProtoConverterTest()
23 : fake_client_(FakeLayerTreeHostClient::DIRECT_3D) {}
24
25 protected: 21 protected:
26 void SetUp() override { 22 void SetUp() override {
27 layer_tree_host_ = 23 layer_tree_host_ =
28 FakeLayerTreeHost::Create(&fake_client_, &task_graph_runner_); 24 FakeLayerTreeHost::Create(&fake_client_, &task_graph_runner_);
29 } 25 }
30 26
31 void TearDown() override { 27 void TearDown() override {
32 layer_tree_host_->SetRootLayer(nullptr); 28 layer_tree_host_->SetRootLayer(nullptr);
33 layer_tree_host_ = nullptr; 29 layer_tree_host_ = nullptr;
34 } 30 }
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 // serialize to. 392 // serialize to.
397 proto::LayerNode layer_node; 393 proto::LayerNode layer_node;
398 new_root->SetTypeForProtoSerialization(&layer_node); 394 new_root->SetTypeForProtoSerialization(&layer_node);
399 EXPECT_EQ(proto::LayerNode::HEADS_UP_DISPLAY_LAYER, layer_node.type()); 395 EXPECT_EQ(proto::LayerNode::HEADS_UP_DISPLAY_LAYER, layer_node.type());
400 396
401 new_root->SetLayerTreeHost(nullptr); 397 new_root->SetLayerTreeHost(nullptr);
402 } 398 }
403 399
404 } // namespace 400 } // namespace
405 } // namespace cc 401 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/layer_position_constraint_unittest.cc ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698