| Index: cc/resources/scoped_resource_unittest.cc
|
| diff --git a/cc/resources/scoped_resource_unittest.cc b/cc/resources/scoped_resource_unittest.cc
|
| index 9c66180df4e736db00a7ada427007353026ee811..f9661fe384e3a7628cacdc65f2a8d0a1408a6a23 100644
|
| --- a/cc/resources/scoped_resource_unittest.cc
|
| +++ b/cc/resources/scoped_resource_unittest.cc
|
| @@ -9,7 +9,6 @@
|
| #include "cc/test/fake_output_surface_client.h"
|
| #include "cc/test/tiled_layer_test_common.h"
|
| #include "testing/gtest/include/gtest/gtest.h"
|
| -#include "third_party/khronos/GLES2/gl2.h"
|
|
|
| namespace cc {
|
| namespace {
|
| @@ -41,15 +40,16 @@ TEST(ScopedResourceTest, CreateScopedResource) {
|
| ResourceProvider::Create(output_surface.get(), 0));
|
| scoped_ptr<ScopedResource> texture =
|
| ScopedResource::create(resource_provider.get());
|
| - texture->Allocate(
|
| - gfx::Size(30, 30), GL_RGBA, ResourceProvider::TextureUsageAny);
|
| + texture->Allocate(gfx::Size(30, 30),
|
| + ResourceProvider::TextureUsageAny,
|
| + RGBA_8888);
|
|
|
| // The texture has an allocated byte-size now.
|
| size_t expected_bytes = 30 * 30 * 4;
|
| EXPECT_EQ(expected_bytes, texture->bytes());
|
|
|
| EXPECT_LT(0u, texture->id());
|
| - EXPECT_EQ(static_cast<unsigned>(GL_RGBA), texture->format());
|
| + EXPECT_EQ(static_cast<unsigned>(RGBA_8888), texture->format());
|
| EXPECT_EQ(gfx::Size(30, 30), texture->size());
|
| }
|
|
|
| @@ -65,8 +65,9 @@ TEST(ScopedResourceTest, ScopedResourceIsDeleted) {
|
| ScopedResource::create(resource_provider.get());
|
|
|
| EXPECT_EQ(0u, resource_provider->num_resources());
|
| - texture->Allocate(
|
| - gfx::Size(30, 30), GL_RGBA, ResourceProvider::TextureUsageAny);
|
| + texture->Allocate(gfx::Size(30, 30),
|
| + ResourceProvider::TextureUsageAny,
|
| + RGBA_8888);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resource_provider->num_resources());
|
| }
|
| @@ -76,8 +77,9 @@ 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), GL_RGBA, ResourceProvider::TextureUsageAny);
|
| + texture->Allocate(gfx::Size(30, 30),
|
| + ResourceProvider::TextureUsageAny,
|
| + RGBA_8888);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resource_provider->num_resources());
|
| texture->Free();
|
| @@ -97,8 +99,9 @@ TEST(ScopedResourceTest, LeakScopedResource) {
|
| ScopedResource::create(resource_provider.get());
|
|
|
| EXPECT_EQ(0u, resource_provider->num_resources());
|
| - texture->Allocate(
|
| - gfx::Size(30, 30), GL_RGBA, ResourceProvider::TextureUsageAny);
|
| + texture->Allocate(gfx::Size(30, 30),
|
| + ResourceProvider::TextureUsageAny,
|
| + RGBA_8888);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resource_provider->num_resources());
|
|
|
|
|