diff --git a/src/test/decompress_test.cpp b/src/test/decompress_test.cpp index f28d253..b98de35 100644 --- a/src/test/decompress_test.cpp +++ b/src/test/decompress_test.cpp @@ -83,6 +83,12 @@ auto main(int, char* argv[]) -> int << "got type: " << static_cast(header->type); }; + test("decompress invalid header") = [] -> void { + const auto result = + decompress(std::span{}, std::span{}); + expect(result.error() == DecompressError::InvalidBlockHeader); + }; + test("no compression") = [] { constexpr auto compressed = huffman::byte_array( 0b000, // no compression, not final