summaryrefslogtreecommitdiffstats
path: root/testsuite/check.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2022-01-09 05:52:40 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2022-01-09 05:53:03 +0000
commit882d8d8da4a8b4a332458c4f01b03d81c2c08c78 (patch)
treed7acd130c7201183b14adfa8e095e79eb1f49bbe /testsuite/check.sh
parentReleasing debian version 0.21-3. (diff)
downloadtarlz-882d8d8da4a8b4a332458c4f01b03d81c2c08c78.tar.xz
tarlz-882d8d8da4a8b4a332458c4f01b03d81c2c08c78.zip
Merging upstream version 0.22.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testsuite/check.sh')
-rwxr-xr-xtestsuite/check.sh19
1 files changed, 18 insertions, 1 deletions
diff --git a/testsuite/check.sh b/testsuite/check.sh
index 25b7055..56aafdb 100755
--- a/testsuite/check.sh
+++ b/testsuite/check.sh
@@ -1,6 +1,6 @@
#! /bin/sh
# check script for Tarlz - Archiver with multimember lzip compression
-# Copyright (C) 2013-2021 Antonio Diaz Diaz.
+# Copyright (C) 2013-2022 Antonio Diaz Diaz.
#
# This script is free software: you have unlimited permission
# to copy, distribute, and modify it.
@@ -115,6 +115,7 @@ cyg_symlink() { [ ${lwarnc} = 0 ] &&
# test3_bad3.tar.lz because their headers are intact.
"${TARLZ}" --check-lib # just print warning
+[ $? != 2 ] || test_failed $LINENO # unless bad lzlib.h
printf "testing tarlz-%s..." "$2"
"${TARLZ}" -q -tf "${in}"
@@ -158,6 +159,8 @@ touch empty.tar.lz empty.tlz # list an empty lz file
"${TARLZ}" -q -tf empty.tlz
[ $? = 2 ] || test_failed $LINENO
rm -f empty.tar.lz empty.tlz || framework_failure
+"${TARLZ}" -q -cd # test mixed operations
+[ $? = 1 ] || test_failed $LINENO
"${TARLZ}" -q -cr
[ $? = 1 ] || test_failed $LINENO
"${TARLZ}" -q -ct
@@ -168,6 +171,14 @@ rm -f empty.tar.lz empty.tlz || framework_failure
[ $? = 1 ] || test_failed $LINENO
"${TARLZ}" -q -ctx
[ $? = 1 ] || test_failed $LINENO
+for i in A c d r t x -delete ; do # test -o with operations other than -z
+ "${TARLZ}" -q -$i -o -
+ [ $? = 1 ] || test_failed $LINENO $i
+done
+"${TARLZ}" -q -z -f -
+[ $? = 1 ] || test_failed $LINENO
+"${TARLZ}" -q -z .
+[ $? = 1 ] || test_failed $LINENO
"${TARLZ}" -q -tf "${in_tar_lz}" ""
[ $? = 1 ] || test_failed $LINENO
"${TARLZ}" --help > /dev/null || test_failed $LINENO
@@ -1059,6 +1070,12 @@ rm -f out3z.tar.lz || framework_failure
[ $? = 1 ] || test_failed $LINENO
cmp out outz.tar.lz || test_failed $LINENO
cmp out3 out3z.tar.lz || test_failed $LINENO
+if [ "${ln_works}" = yes ] ; then
+ ln -s outz.tar loutz.tar || framework_failure
+ "${TARLZ}" -0 -z loutz.tar || test_failed $LINENO
+ cmp loutz.tar.lz outz.tar.lz || test_failed $LINENO
+ rm -f loutz.tar.lz loutz.tar || framework_failure
+fi
rm -f out out3 outz.tar.lz out3z.tar.lz || framework_failure
#
for i in --solid --no-solid ; do