Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "platform/image-decoders/ico/ICOImageDecoder.h" | |
| 6 | |
| 7 #include "platform/image-decoders/ImageDecoderTestHelpers.h" | |
| 8 #include "testing/gtest/include/gtest/gtest.h" | |
| 9 | |
| 10 namespace blink { | |
| 11 | |
| 12 namespace { | |
| 13 | |
| 14 PassOwnPtr<ImageDecoder> createDecoder() | |
| 15 { | |
| 16 return adoptPtr(new ICOImageDecoder(ImageDecoder::AlphaNotPremultiplied, Ima geDecoder::GammaAndColorProfileApplied, ImageDecoder::noDecodedImageByteLimit)); | |
| 17 } | |
| 18 | |
| 19 } // anonymous namespace | |
|
Peter Kasting
2016/06/08 23:16:13
Nit: I'd just remove this comment since the namesp
aleksandar.stojiljkovic
2016/06/09 20:34:07
Done.
| |
| 20 | |
| 21 TEST(ICOImageDecoderTests, parseAndDecodeByteByByte) | |
| 22 { | |
| 23 testByteByByteDecode(&createDecoder, "/LayoutTests/fast/images/resources/2en tries.ico", 2u, cAnimationNone); | |
| 24 testByteByByteDecode(&createDecoder, "/LayoutTests/fast/events/resources/gre enbox-3frames.cur", 3u, cAnimationNone); | |
| 25 testByteByByteDecode(&createDecoder, "/LayoutTests/http/tests/favicon.ico", 1u, cAnimationNone); | |
| 26 testByteByByteDecode(&createDecoder, "/LayoutTests/fast/images/resources/ico n-without-and-bitmap.ico", 1u, cAnimationNone); | |
| 27 testByteByByteDecode(&createDecoder, "/LayoutTests/fast/images/resources/1bi t.ico", 1u, cAnimationNone); | |
| 28 } | |
| 29 | |
| 30 } // namespace blink | |
| OLD | NEW |