flate2-rs icon indicating copy to clipboard operation
flate2-rs copied to clipboard

Add unit tests of the different flush kinds

Open fintelia opened this issue 5 months ago • 3 comments

This PR adds tests of the various flush kinds to ensure that all backends implement them consistently. The cases are carefully constructed so that even quite different backend implementations are likely to produce the expected output. In particular, it counts on the encoder detecting when the input is/isn't compressible and writing either compressed or stored blocks accordingly.

Tests pass for me with the zlib, zlib-ng, zlib-rs and cloudflare_zlib backends. The miniz_oxide backend requires https://github.com/Frommi/miniz_oxide/pull/179 as otherwise it treats partial flushes as "no flush" (!)

fintelia avatar Jul 20 '25 04:07 fintelia

Could we get this done towards the end of the year? Maybe it works now if the PR was rebased?

Byron avatar Dec 09 '25 03:12 Byron

Right, thanks a lot!

I think I may have asked @oyvindln that before and apologise this question is redundant or repetitive, but given my ignorance, is a release of miniz_oxide in the cards till the end of the year? Thanks (and sorry) again.

Byron avatar Dec 09 '25 16:12 Byron

Yeah I'm hoping to get something out before the end of the year, just need to resolve a few small things.

oyvindln avatar Dec 09 '25 18:12 oyvindln