mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 13:47:46 +00:00
Tests: Add regression tests for fixed OSS-Fuzz test cases
This commit is contained in:
parent
c62dded5cc
commit
cb16c217b8
18 changed files with 119 additions and 0 deletions
|
@ -12,3 +12,7 @@ install(FILES vp9_4k.webm DESTINATION usr/Tests/LibVideo)
|
|||
install(FILES vp9_clamp_reference_mvs.webm DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES vp9_oob_blocks.webm DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES master_elements_containing_crc32.mkv DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES oss-fuzz-testcase-52630.vp9 DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES oss-fuzz-testcase-53977.vp9 DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES oss-fuzz-testcase-62054.vp9 DESTINATION usr/Tests/LibVideo)
|
||||
install(FILES oss-fuzz-testcase-63182.vp9 DESTINATION usr/Tests/LibVideo)
|
||||
|
|
|
@ -59,6 +59,23 @@ TEST_CASE(vp9_oob_blocks)
|
|||
decode_video("./vp9_oob_blocks.webm"sv, 240);
|
||||
}
|
||||
|
||||
TEST_CASE(vp9_malformed_frame)
|
||||
{
|
||||
Array test_inputs = {
|
||||
"./oss-fuzz-testcase-52630.vp9"sv,
|
||||
"./oss-fuzz-testcase-53977.vp9"sv,
|
||||
"./oss-fuzz-testcase-62054.vp9"sv,
|
||||
"./oss-fuzz-testcase-63182.vp9"sv
|
||||
};
|
||||
|
||||
for (auto test_input : test_inputs) {
|
||||
auto file = MUST(Core::MappedFile::map(test_input));
|
||||
Video::VP9::Decoder vp9_decoder;
|
||||
auto maybe_decoder_error = vp9_decoder.receive_sample(file->bytes());
|
||||
EXPECT(maybe_decoder_error.is_error());
|
||||
}
|
||||
}
|
||||
|
||||
BENCHMARK_CASE(vp9_4k)
|
||||
{
|
||||
decode_video("./vp9_4k.webm"sv, 2);
|
||||
|
|
BIN
Tests/LibVideo/oss-fuzz-testcase-52630.vp9
Normal file
BIN
Tests/LibVideo/oss-fuzz-testcase-52630.vp9
Normal file
Binary file not shown.
BIN
Tests/LibVideo/oss-fuzz-testcase-53977.vp9
Normal file
BIN
Tests/LibVideo/oss-fuzz-testcase-53977.vp9
Normal file
Binary file not shown.
1
Tests/LibVideo/oss-fuzz-testcase-62054.vp9
Normal file
1
Tests/LibVideo/oss-fuzz-testcase-62054.vp9
Normal file
|
@ -0,0 +1 @@
|
|||
‚I<EFBFBD>B˙
|
BIN
Tests/LibVideo/oss-fuzz-testcase-63182.vp9
Normal file
BIN
Tests/LibVideo/oss-fuzz-testcase-63182.vp9
Normal file
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue