4
0

multiv07.at 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. # Test suite for GNU tar. -*- Autotest -*-
  2. # Copyright 2010-2023 Free Software Foundation, Inc.
  3. # This file is part of GNU tar.
  4. # GNU tar is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 3 of the License, or
  7. # (at your option) any later version.
  8. # GNU tar is distributed in the hope that it will be useful,
  9. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. # GNU General Public License for more details.
  12. # You should have received a copy of the GNU General Public License
  13. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. # Description: When creating POSIX multivolume archives, tar may in
  15. # some cases write an extended header at the end of one volume, and
  16. # the corresponding ustar header at the beginning of the next volume.
  17. # Such archives do not fully comply with the POSIX specs, but tar must
  18. # be able to read them anyway. This is what this script tests.
  19. #
  20. # See function try_new_volume, in file src/buffer.c near line 1227
  21. # for additional details.
  22. AT_SETUP([volumes split at an extended header])
  23. AT_KEYWORDS([multivolume multiv multiv07 xsplit])
  24. AT_CHECK([
  25. AT_XFAIL_IF(test -f $[]XFAILFILE)
  26. AT_TARBALL_PREREQ([xsplit-1.tar],[0e008c84c517e48fbf23ca6a7033cde6])
  27. AT_TARBALL_PREREQ([xsplit-2.tar],[03150b9852d285458f43734e9e0b9a45])
  28. exec <&-
  29. cd $TEST_DATA_DIR
  30. tar -t -M -fxsplit-1.tar -fxsplit-2.tar
  31. ],
  32. [0],
  33. [Archive volumes split at an extended header Volume 1
  34. foo
  35. bar
  36. ])
  37. AT_CLEANUP