commons-compress icon indicating copy to clipboard operation
commons-compress copied to clipboard

COMPRESS-675 -- create unit test for COMPRESS-675

Open tballison opened this issue 1 year ago • 2 comments

unit test for putting two unpack files within an archive

tballison avatar Apr 05 '24 16:04 tballison

@garydgregory This is either user error or something is really wrong with unpack.

I couldn't get this test to pass with a tar archive stream or a zip archive stream -- different results!

I couldn't get this test to pass with a FIleInputStream, a BufferedInputStream(ByteArrayInputStream) or a Files.newInputStream(archive.toPath)

In the debugger on the Tika issue, I can see that Unpack unwraps down to a ChannelInputStream and then closes the underlying file. I can see similar behavior in this unit test if I open with Files.newInputStream()...so that's what you can use to replicate what we're seeing on Tika.

I'm perplexed that I can't get anything to pass, though... again, probably user error.

tballison avatar Apr 05 '24 16:04 tballison

Hi @tballison Would you please rebase on git master? Let's see what the tests say this time around...

garydgregory avatar Jun 28 '24 20:06 garydgregory

Fixed, seeL https://issues.apache.org/jira/browse/COMPRESS-675

sebbASF avatar Jul 29 '24 19:07 sebbASF