| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "platform/image-decoders/ImageDecoderTestHelpers.h" | 5 #include "platform/image-decoders/ImageDecoderTestHelpers.h" |
| 6 | 6 |
| 7 #include "platform/SharedBuffer.h" | 7 #include "platform/SharedBuffer.h" |
| 8 #include "platform/image-decoders/ImageDecoder.h" | 8 #include "platform/image-decoders/ImageDecoder.h" |
| 9 #include "platform/image-decoders/ImageFrame.h" | |
| 10 #include "public/platform/Platform.h" | 9 #include "public/platform/Platform.h" |
| 11 #include "public/platform/WebUnitTestSupport.h" | 10 #include "public/platform/WebUnitTestSupport.h" |
| 12 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
| 13 #include "wtf/OwnPtr.h" | 12 #include "wtf/OwnPtr.h" |
| 14 #include "wtf/StringHasher.h" | 13 #include "wtf/StringHasher.h" |
| 15 | 14 |
| 16 namespace blink { | 15 namespace blink { |
| 17 | 16 |
| 18 PassRefPtr<SharedBuffer> readFile(const char* fileName) | 17 PassRefPtr<SharedBuffer> readFile(const char* fileName) |
| 19 { | 18 { |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 // data in a segment, its pointer would no longer be valid. | 132 // data in a segment, its pointer would no longer be valid. |
| 134 segmentedData->data(); | 133 segmentedData->data(); |
| 135 | 134 |
| 136 ImageFrame* frame = decoder->frameBufferAtIndex(0); | 135 ImageFrame* frame = decoder->frameBufferAtIndex(0); |
| 137 ASSERT_FALSE(decoder->failed()); | 136 ASSERT_FALSE(decoder->failed()); |
| 138 EXPECT_EQ(frame->status(), ImageFrame::FrameComplete); | 137 EXPECT_EQ(frame->status(), ImageFrame::FrameComplete); |
| 139 EXPECT_EQ(hashBitmap(frame->bitmap()), hash); | 138 EXPECT_EQ(hashBitmap(frame->bitmap()), hash); |
| 140 } | 139 } |
| 141 | 140 |
| 142 } // namespace blink | 141 } // namespace blink |
| OLD | NEW |