| Index: third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp
|
| diff --git a/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp b/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp
|
| index ca2d94135deea63d6b2b6908bfb359519af156df..e52a2a38f741abfaf77576ce90ebfe748163e700 100644
|
| --- a/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp
|
| +++ b/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp
|
| @@ -326,8 +326,6 @@ TEST_F(DrawingBufferImageChromiumTest, verifyResizingReallocatesImages) {
|
| EXPECT_CALL(*m_gl, BindTexImage2DMock(m_imageId2)).Times(1);
|
| EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId0)).Times(1);
|
| EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId0)).Times(1);
|
| - EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId1)).Times(1);
|
| - EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId1)).Times(1);
|
| // Resize to 100x50.
|
| m_drawingBuffer->reset(alternateSize);
|
| releaseCallback->Run(gpu::SyncToken(), false /* lostResource */);
|
| @@ -337,6 +335,8 @@ TEST_F(DrawingBufferImageChromiumTest, verifyResizingReallocatesImages) {
|
| EXPECT_CALL(*m_gl, BindTexImage2DMock(m_imageId3)).Times(1);
|
| // Produce a mailbox at this size.
|
| m_drawingBuffer->markContentsChanged();
|
| + EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId1)).Times(1);
|
| + EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId1)).Times(1);
|
| EXPECT_TRUE(m_drawingBuffer->PrepareTextureMailbox(&textureMailbox,
|
| &releaseCallback));
|
| EXPECT_EQ(alternateSize, m_gl->mostRecentlyProducedSize());
|
| @@ -347,8 +347,6 @@ TEST_F(DrawingBufferImageChromiumTest, verifyResizingReallocatesImages) {
|
| EXPECT_CALL(*m_gl, BindTexImage2DMock(m_imageId4)).Times(1);
|
| EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId2)).Times(1);
|
| EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId2)).Times(1);
|
| - EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId3)).Times(1);
|
| - EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId3)).Times(1);
|
| // Reset to initial size.
|
| m_drawingBuffer->reset(initialSize);
|
| releaseCallback->Run(gpu::SyncToken(), false /* lostResource */);
|
| @@ -358,6 +356,8 @@ TEST_F(DrawingBufferImageChromiumTest, verifyResizingReallocatesImages) {
|
| EXPECT_CALL(*m_gl, BindTexImage2DMock(m_imageId5)).Times(1);
|
| // Prepare another mailbox and verify that it's the correct size.
|
| m_drawingBuffer->markContentsChanged();
|
| + EXPECT_CALL(*m_gl, DestroyImageMock(m_imageId3)).Times(1);
|
| + EXPECT_CALL(*m_gl, ReleaseTexImage2DMock(m_imageId3)).Times(1);
|
| EXPECT_TRUE(m_drawingBuffer->PrepareTextureMailbox(&textureMailbox,
|
| &releaseCallback));
|
| EXPECT_EQ(initialSize, m_gl->mostRecentlyProducedSize());
|
|
|