mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-09 09:34:57 +09:00
Tests/LibGfx: Add test for top-down BMP files
This commit is contained in:
parent
a9208a18ca
commit
d76ad23492
Notes:
sideshowbarker
2024-07-17 05:19:06 +09:00
Author: https://github.com/circl-lastname
Commit: d76ad23492
Pull-request: https://github.com/SerenityOS/serenity/pull/21490
3 changed files with 10 additions and 1 deletions
|
@ -53,7 +53,16 @@ static Gfx::ImageFrameDescriptor expect_single_frame_of_size(Gfx::ImageDecoderPl
|
|||
|
||||
TEST_CASE(test_bmp)
|
||||
{
|
||||
auto file = MUST(Core::MappedFile::map(TEST_INPUT("rgba32-1.bmp"sv)));
|
||||
auto file = MUST(Core::MappedFile::map(TEST_INPUT("bmp/rgba32-1.bmp"sv)));
|
||||
EXPECT(Gfx::BMPImageDecoderPlugin::sniff(file->bytes()));
|
||||
auto plugin_decoder = MUST(Gfx::BMPImageDecoderPlugin::create(file->bytes()));
|
||||
|
||||
expect_single_frame(*plugin_decoder);
|
||||
}
|
||||
|
||||
TEST_CASE(test_bmp_top_down)
|
||||
{
|
||||
auto file = MUST(Core::MappedFile::map(TEST_INPUT("bmp/top-down.bmp"sv)));
|
||||
EXPECT(Gfx::BMPImageDecoderPlugin::sniff(file->bytes()));
|
||||
auto plugin_decoder = MUST(Gfx::BMPImageDecoderPlugin::create(file->bytes()));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue