fparkan/vendor/flate2/tests/zero-write.rs
Valentin Popov 1b6a04ca55
Initial vendor packages
Signed-off-by: Valentin Popov <valentin@popov.link>
2024-01-08 01:21:28 +04:00

7 lines
200 B
Rust

#[test]
fn zero_write_is_error() {
let mut buf = [0u8];
let writer = flate2::write::DeflateEncoder::new(&mut buf[..], flate2::Compression::default());
assert!(writer.finish().is_err());
}