| Index: cc/surfaces/surface_factory_unittest.cc
|
| diff --git a/cc/surfaces/surface_factory_unittest.cc b/cc/surfaces/surface_factory_unittest.cc
|
| index be74ec3beb149b74bcea9d22d407cbc8b0f96c7f..a66297811f1a205c82355884fb9d9fc9f1056e6e 100644
|
| --- a/cc/surfaces/surface_factory_unittest.cc
|
| +++ b/cc/surfaces/surface_factory_unittest.cc
|
| @@ -69,7 +69,7 @@ class SurfaceFactoryTest : public testing::Test, public SurfaceObserver {
|
| SurfaceFactoryTest()
|
| : factory_(
|
| new SurfaceFactory(kArbitraryFrameSinkId, &manager_, &client_)),
|
| - local_frame_id_(3, 0),
|
| + local_frame_id_(3, 1),
|
| frame_sync_token_(GenTestSyncToken(4)),
|
| consumer_sync_token_(GenTestSyncToken(5)) {
|
| manager_.AddObserver(this);
|
| @@ -93,7 +93,7 @@ class SurfaceFactoryTest : public testing::Test, public SurfaceObserver {
|
| }
|
|
|
| ~SurfaceFactoryTest() override {
|
| - if (!local_frame_id_.is_null())
|
| + if (local_frame_id_.is_valid())
|
| factory_->Destroy(local_frame_id_);
|
| manager_.RemoveObserver(this);
|
| }
|
| @@ -436,7 +436,7 @@ TEST_F(SurfaceFactoryTest, ResourceLifetime) {
|
| }
|
|
|
| TEST_F(SurfaceFactoryTest, BlankNoIndexIncrement) {
|
| - LocalFrameId local_frame_id(6, 0);
|
| + LocalFrameId local_frame_id(6, 1);
|
| SurfaceId surface_id(kArbitraryFrameSinkId, local_frame_id);
|
| factory_->Create(local_frame_id);
|
| Surface* surface = manager_.GetSurfaceForId(surface_id);
|
| @@ -461,7 +461,7 @@ void CreateSurfaceDrawCallback(SurfaceFactory* factory,
|
| }
|
|
|
| TEST_F(SurfaceFactoryTest, AddDuringDestroy) {
|
| - LocalFrameId local_frame_id(6, 0);
|
| + LocalFrameId local_frame_id(6, 1);
|
| factory_->Create(local_frame_id);
|
| CompositorFrame frame;
|
| frame.delegated_frame_data.reset(new DelegatedFrameData);
|
| @@ -482,7 +482,7 @@ void DrawCallback(uint32_t* execute_count) {
|
|
|
| // Tests doing a DestroyAll before shutting down the factory;
|
| TEST_F(SurfaceFactoryTest, DestroyAll) {
|
| - LocalFrameId id(7, 0);
|
| + LocalFrameId id(7, 1);
|
| factory_->Create(id);
|
|
|
| std::unique_ptr<DelegatedFrameData> frame_data(new DelegatedFrameData);
|
| @@ -496,8 +496,8 @@ TEST_F(SurfaceFactoryTest, DestroyAll) {
|
| factory_->SubmitCompositorFrame(id, std::move(frame),
|
| base::Bind(&DrawCallback, &execute_count));
|
| EXPECT_EQ(last_created_surface_id().local_frame_id(), id);
|
| - local_frame_id_ = LocalFrameId();
|
| factory_->DestroyAll();
|
| + local_frame_id_ = LocalFrameId();
|
| EXPECT_EQ(1u, execute_count);
|
| }
|
|
|
|
|