multiv06.at 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. # Process this file with autom4te to create testsuite. -*- Autotest -*-
  2. # Test suite for GNU tar.
  3. # Copyright (C) 2008 Free Software Foundation, Inc.
  4. # This program 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, or (at your option)
  7. # any later version.
  8. # This program 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, write to the Free Software
  14. # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  15. # 02110-1301, USA.
  16. # When volume size equals record size, swapping buffers in
  17. # new_volume triggers a call to flush_archive. The size left variables
  18. # must be corrected after that, which was not done in versions <= 1.20.
  19. # Reported by: Marek Kielar <[email protected]>
  20. # References: <[email protected]>
  21. AT_SETUP([Multivolumes with L=record_size])
  22. AT_KEYWORDS([multivolume multiv multiv06])
  23. m4_define([echo2],[
  24. echo $*
  25. echo >&2 $*
  26. ])
  27. AT_TAR_CHECK([
  28. exec <&-
  29. echo2("Creating file")
  30. genfile --length 20139 --file file
  31. echo2("Creating archive")
  32. tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
  33. echo2("Testing archive")
  34. tar -t -M -farc.1 -farc.2 -farc.3],
  35. [0],
  36. [Creating file
  37. Creating archive
  38. Testing archive
  39. file
  40. ],
  41. [Creating file
  42. Creating archive
  43. Testing archive
  44. ],
  45. [],[],
  46. [gnu, pax])
  47. AT_CLEANUP