tar: add a testcase for previous commit
authorDenys Vlasenko <vda.linux@googlemail.com>
Tue, 19 Nov 2013 13:52:02 +0000 (14:52 +0100)
committerDenys Vlasenko <vda.linux@googlemail.com>
Tue, 19 Nov 2013 13:52:02 +0000 (14:52 +0100)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
testsuite/tar.tests

index 7927020c113dee39f593ea0cde5d40e2670c0f2c..1bdd5d43738e28a356ec95f77dc1a38813aa7c09 100755 (executable)
@@ -15,6 +15,18 @@ mkdir tar.tempdir && cd tar.tempdir || exit 1
 
 # testing "test name" "script" "expected result" "file input" "stdin"
 
+# Empty file is not a valid .tar.gz:
+optional FEATURE_SEAMLESS_GZ
+testing "tar hardlinks and repeated files" '\
+tar xvzf - 2>&1; echo $?
+' "\
+tar: invalid magic
+tar: short read
+1
+" \
+"" ""
+SKIP=
+
 optional FEATURE_TAR_CREATE FEATURE_LS_SORTFILES
 testing "tar hardlinks and repeated files" '\
 rm -rf input_* test.tar 2>/dev/null