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

Side by Side Diff: cc/surfaces/surface_manager_unittest.cc

Issue 1778853003: Fold BeginFrameSource::SetClientReady into AddObserver (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scheduler_always_external
Patch Set: Created 4 years, 9 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/scheduler/scheduler.cc ('k') | cc/test/fake_external_begin_frame_source.h » ('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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 <stddef.h> 5 #include <stddef.h>
6 6
7 #include "cc/scheduler/begin_frame_source.h" 7 #include "cc/scheduler/begin_frame_source.h"
8 #include "cc/surfaces/surface_factory_client.h" 8 #include "cc/surfaces/surface_factory_client.h"
9 #include "cc/surfaces/surface_manager.h" 9 #include "cc/surfaces/surface_manager.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 BeginFrameSource* source_; 54 BeginFrameSource* source_;
55 SurfaceManager* manager_; 55 SurfaceManager* manager_;
56 uint32_t id_namespace_; 56 uint32_t id_namespace_;
57 }; 57 };
58 58
59 class EmptyBeginFrameSource : public BeginFrameSource { 59 class EmptyBeginFrameSource : public BeginFrameSource {
60 public: 60 public:
61 void DidFinishFrame(size_t remaining_frames) override{}; 61 void DidFinishFrame(size_t remaining_frames) override{};
62 void AddObserver(BeginFrameObserver* obs) override{}; 62 void AddObserver(BeginFrameObserver* obs) override{};
63 void RemoveObserver(BeginFrameObserver* obs) override{}; 63 void RemoveObserver(BeginFrameObserver* obs) override{};
64 void SetClientReady() override {}
65 void AsValueInto(base::trace_event::TracedValue* dict) const override{}; 64 void AsValueInto(base::trace_event::TracedValue* dict) const override{};
66 }; 65 };
67 66
68 class SurfaceManagerTest : public testing::Test { 67 class SurfaceManagerTest : public testing::Test {
69 public: 68 public:
70 // These tests don't care about namespace registration, so just preregister 69 // These tests don't care about namespace registration, so just preregister
71 // a set of namespaces that tests can use freely without worrying if they're 70 // a set of namespaces that tests can use freely without worrying if they're
72 // valid or not. 71 // valid or not.
73 enum { MAX_NAMESPACE = 10 }; 72 enum { MAX_NAMESPACE = 10 };
74 73
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 } 372 }
374 373
375 INSTANTIATE_TEST_CASE_P( 374 INSTANTIATE_TEST_CASE_P(
376 SurfaceManagerOrderingParamTestInstantiation, 375 SurfaceManagerOrderingParamTestInstantiation,
377 SurfaceManagerOrderingParamTest, 376 SurfaceManagerOrderingParamTest,
378 ::testing::Combine(::testing::ValuesIn(kRegisterOrderList), 377 ::testing::Combine(::testing::ValuesIn(kRegisterOrderList),
379 ::testing::ValuesIn(kUnregisterOrderList), 378 ::testing::ValuesIn(kUnregisterOrderList),
380 ::testing::ValuesIn(kBFSOrderList))); 379 ::testing::ValuesIn(kBFSOrderList)));
381 380
382 } // namespace cc 381 } // namespace cc
OLDNEW
« no previous file with comments | « cc/scheduler/scheduler.cc ('k') | cc/test/fake_external_begin_frame_source.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698