Add test to confirm that piping a tar archive created by bsdtar through

'bsdtar -cf- @-' doesn't alter it.
This commit is contained in:
Colin Percival 2007-04-04 03:12:15 +00:00
parent 9160afee7c
commit 17c0c70552
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=168343

View File

@ -359,6 +359,11 @@ mkdir filter-tar-tar
(cd original && ${BSDTAR} -cf - .) | ${BSDTAR} -cf - @- | (cd filter-tar-tar; ${BSDTAR} -xf -)
diff -r original filter-tar-tar || echo XXX FAILED XXX
# Make sure that reading and writing a tar archive doesn't change it.
echo " bsdtar -cf- @- | cmp"
(cd original && ${BSDTAR} -cf - .) > original.tar
${BSDTAR} -cf - @- < original.tar | cmp - original.tar || echo XXX FAILED XXX
# Filtering as format conversion
echo " Convert tar archive to cpio archive"
mkdir filter-tar-cpio