Index: Source/platform/image-decoders/ImageDecoderTest.cpp |
diff --git a/Source/platform/image-decoders/ImageDecoderTest.cpp b/Source/platform/image-decoders/ImageDecoderTest.cpp |
index 9d4ba3b742ff66f2af84ea671d46183ebb22e146..bd52b1377397a6b3c1bcecd7d30234682fffc5b1 100644 |
--- a/Source/platform/image-decoders/ImageDecoderTest.cpp |
+++ b/Source/platform/image-decoders/ImageDecoderTest.cpp |
@@ -228,6 +228,18 @@ TEST(ImageDecoderTest, clearCacheExceptFrameAll) |
} |
} |
+TEST(ImageDecoderTest, clearCacheExceptFrameAllSingleFrame) |
+{ |
+ OwnPtr<TestImageDecoder> decoder(adoptPtr(new TestImageDecoder())); |
+ decoder->initFrames(1); |
+ ImageFrame* frame = &decoder->frameBufferCache().first(); |
+ frame->setStatus(ImageFrame::FrameComplete); |
+ |
+ decoder->clearCacheExceptFrame(kNotFound); |
+ |
Peter Kasting
2014/01/14 20:04:49
Nit: Extra blank line (line 224 could probably als
fs
2014/01/15 09:48:24
Will prune.
|
+ EXPECT_EQ(ImageFrame::FrameEmpty, frame->status()); |
+} |
+ |
TEST(ImageDecoderTest, clearCacheExceptFramePreverveClearExceptFrame) |
{ |
const size_t numFrames = 10; |