diff options
Diffstat (limited to 'cc/resources/scoped_resource_unittest.cc')
-rw-r--r-- | cc/resources/scoped_resource_unittest.cc | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/cc/resources/scoped_resource_unittest.cc b/cc/resources/scoped_resource_unittest.cc index 5042221..5b5f143 100644 --- a/cc/resources/scoped_resource_unittest.cc +++ b/cc/resources/scoped_resource_unittest.cc @@ -45,9 +45,8 @@ TEST(ScopedResourceTest, CreateScopedResource) { output_surface.get(), shared_bitmap_manager.get(), 0, false, 1, false)); scoped_ptr<ScopedResource> texture = ScopedResource::Create(resource_provider.get()); - texture->Allocate(gfx::Size(30, 30), - ResourceProvider::TextureUsageAny, - RGBA_8888); + texture->Allocate( + gfx::Size(30, 30), ResourceProvider::TextureHintImmutable, RGBA_8888); // The texture has an allocated byte-size now. size_t expected_bytes = 30 * 30 * 4; @@ -72,9 +71,8 @@ TEST(ScopedResourceTest, ScopedResourceIsDeleted) { ScopedResource::Create(resource_provider.get()); EXPECT_EQ(0u, resource_provider->num_resources()); - texture->Allocate(gfx::Size(30, 30), - ResourceProvider::TextureUsageAny, - RGBA_8888); + texture->Allocate( + gfx::Size(30, 30), ResourceProvider::TextureHintImmutable, RGBA_8888); EXPECT_LT(0u, texture->id()); EXPECT_EQ(1u, resource_provider->num_resources()); } @@ -84,9 +82,8 @@ TEST(ScopedResourceTest, ScopedResourceIsDeleted) { scoped_ptr<ScopedResource> texture = ScopedResource::Create(resource_provider.get()); EXPECT_EQ(0u, resource_provider->num_resources()); - texture->Allocate(gfx::Size(30, 30), - ResourceProvider::TextureUsageAny, - RGBA_8888); + texture->Allocate( + gfx::Size(30, 30), ResourceProvider::TextureHintImmutable, RGBA_8888); EXPECT_LT(0u, texture->id()); EXPECT_EQ(1u, resource_provider->num_resources()); texture->Free(); @@ -108,9 +105,8 @@ TEST(ScopedResourceTest, LeakScopedResource) { ScopedResource::Create(resource_provider.get()); EXPECT_EQ(0u, resource_provider->num_resources()); - texture->Allocate(gfx::Size(30, 30), - ResourceProvider::TextureUsageAny, - RGBA_8888); + texture->Allocate( + gfx::Size(30, 30), ResourceProvider::TextureHintImmutable, RGBA_8888); EXPECT_LT(0u, texture->id()); EXPECT_EQ(1u, resource_provider->num_resources()); |