diff options
Diffstat (limited to 'ripple/fossil')
-rw-r--r-- | ripple/fossil/src/chunker/mod.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ripple/fossil/src/chunker/mod.rs b/ripple/fossil/src/chunker/mod.rs index 108d5de..07b3e8d 100644 --- a/ripple/fossil/src/chunker/mod.rs +++ b/ripple/fossil/src/chunker/mod.rs @@ -196,4 +196,15 @@ mod test { super::MIN_CHUNK_SIZE ); } + + #[test] + fn short_chunk() { + assert_eq!( + super::Chunker::from(&[0u8; super::MIN_CHUNK_SIZE / 2]) + .next() + .unwrap() + .len(), + super::MIN_CHUNK_SIZE / 2 + ); + } } |