Added new tests
This commit is contained in:
@@ -23,19 +23,36 @@
|
||||
check_PROGRAMS = genfile mksparse
|
||||
BUILT_SOURCES = preset
|
||||
|
||||
TESTS = version.sh \
|
||||
append.sh delete01.sh delete02.sh delete03.sh delete04.sh \
|
||||
extrac01.sh extrac02.sh extrac03.sh extrac04.sh \
|
||||
gzip.sh incremen.sh ignfail.sh listed01.sh \
|
||||
longv7.sh multiv01.sh old.sh options.sh volume.sh \
|
||||
recurse.sh \
|
||||
star/gtarfail.sh \
|
||||
star/gtarfail2.sh \
|
||||
star/multi-fail.sh \
|
||||
star/ustar-big-2g.sh \
|
||||
star/ustar-big-8g.sh \
|
||||
star/pax-big-10g.sh \
|
||||
star/qucktest.sh
|
||||
TESTS = \
|
||||
version.sh\
|
||||
append.sh\
|
||||
delete01.sh\
|
||||
delete02.sh\
|
||||
delete03.sh\
|
||||
delete04.sh\
|
||||
extrac01.sh\
|
||||
extrac02.sh\
|
||||
extrac03.sh\
|
||||
extrac04.sh\
|
||||
gzip.sh\
|
||||
incremen.sh\
|
||||
ignfail.sh\
|
||||
listed01.sh\
|
||||
longv7.sh\
|
||||
multiv01.sh\
|
||||
multiv02.sh\
|
||||
old.sh\
|
||||
options.sh\
|
||||
volume.sh\
|
||||
recurse.sh\
|
||||
sparse01.sh\
|
||||
star/gtarfail.sh\
|
||||
star/gtarfail2.sh\
|
||||
star/multi-fail.sh\
|
||||
star/ustar-big-2g.sh\
|
||||
star/ustar-big-8g.sh\
|
||||
star/pax-big-10g.sh\
|
||||
star/qucktest.sh
|
||||
|
||||
genfile_SOURCES = genfile.c
|
||||
mksparse_SOURCES = mksparse.c
|
||||
|
||||
43
tests/multiv02.sh
Executable file
43
tests/multiv02.sh
Executable file
@@ -0,0 +1,43 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Previous versions of tar were not able to skip a member straddling
|
||||
# the multivolume archive boundary. Reported by Mads Martin Joergensen
|
||||
# <mmj@suse.de>
|
||||
|
||||
# This file is part of GNU tar testsuite.
|
||||
# Copyright (C) 2004 Free Software Foundation, Inc.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
# 02111-1307, USA.
|
||||
|
||||
. ./preset
|
||||
TAR_ARCHIVE_FORMATS="gnu oldgnu"
|
||||
. $srcdir/before
|
||||
|
||||
genfile --length 10240 > en
|
||||
genfile --length 20000 > to
|
||||
genfile --length 20000 > tre
|
||||
genfile --length 10240 > fire
|
||||
|
||||
tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire
|
||||
echo separator
|
||||
tar -v -x -f A.tar -f B.tar -f C.tar -M en
|
||||
|
||||
out="\
|
||||
separator
|
||||
en
|
||||
"
|
||||
|
||||
. $srcdir/after
|
||||
42
tests/sparse01.sh
Executable file
42
tests/sparse01.sh
Executable file
@@ -0,0 +1,42 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Check sparse file handling.
|
||||
|
||||
# This file is part of GNU tar testsuite.
|
||||
# Copyright (C) 2004 Free Software Foundation, Inc.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
# 02111-1307, USA.
|
||||
|
||||
. ./preset
|
||||
TAR_ARCHIVE_FORMATS="gnu oldgnu posix"
|
||||
. $srcdir/before
|
||||
|
||||
genfile --length 1000 > begin
|
||||
genfile --length 1000 > end
|
||||
mksparse sparsefile 512 0 ABCD 1M EFGH 2000K IJKL
|
||||
tar -c -f archive --sparse begin sparsefile end
|
||||
echo separator
|
||||
|
||||
tar tfv archive
|
||||
|
||||
out_regex="\
|
||||
separator
|
||||
-rw-r--r-- [^ ][^ ]* *1000 [0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] [0-9][0-9]:[0-9][0-9] begin
|
||||
-rw-r--r-- [^ ][^ ]* *10344448[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] [0-9][0-9]:[0-9][0-9] sparsefile
|
||||
-rw-r--r-- [^ ][^ ]* *1000 [0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] [0-9][0-9]:[0-9][0-9] end
|
||||
"
|
||||
|
||||
. $srcdir/after
|
||||
Reference in New Issue
Block a user