tar-stream/test/fixtures/incomplete.tar
sth 689d3fafd5 Trigger an error if there is an incomplete entry at the end of stream (#83)
* Check if there is an incomplete entry at the end of the input

An error will be raised if the last entry wans't complete.

This will only work in node >= v8, since that's where _final()
was introduced. Older node versions will ignore that function and
will be unaffected.

* Add padding at the end of gnu-long-path.tar

This test case file was actually to short. The new code checking for
unexpected end of file rejected it. Gnu tar agrees, it also failed to
extract it with "Unexpected EOF in archive".

* Added test case to check handling of incomplete data

This tests that an error event is created when the input file
is incomplete.

* Check callback directly instead of passing extra parameter
2018-04-26 17:00:57 +02:00

1,000 B