denyhosts/clamav/libclamav_rust/.cargo/vendor/flate2/tests/zero-write.rs

9 lines
222 B
Rust
Raw Normal View History

2023-01-14 18:28:39 +08:00
extern crate flate2;
#[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());
}