Testsuite fixes.
* paxutils: Update. * src/unlink.c (flush_deferred_unlinks): OpenSolaris sets EEXIST instead of ENOTEMPTY if trying to remove a non-empty directory. * tests/numeric.at: Avoid using awk -v: some older awks don't support that option. Also fix environment variable usage. * tests/onetop05.at: Skip test if unable to set initial directory mode bits. * tests/sparse06.at: Use --quiet option.
This commit is contained in:
2
paxutils
2
paxutils
Submodule paxutils updated: 58b8ac1147...ec72abd9dd
@@ -124,6 +124,9 @@ flush_deferred_unlinks (bool force)
|
||||
case ENOENT:
|
||||
/* nothing to worry about */
|
||||
break;
|
||||
case EEXIST:
|
||||
/* OpenSolaris >=10 sets EEXIST instead of ENOTEMPTY
|
||||
if trying to remove a non-empty directory */
|
||||
case ENOTEMPTY:
|
||||
/* Keep the record in list, in the hope we'll
|
||||
be able to remove it later */
|
||||
|
||||
@@ -21,9 +21,9 @@ AT_KEYWORDS([options numeric numeric-owner])
|
||||
m4_pushdef([TESTOP],[
|
||||
decho $1
|
||||
tar $1 -vvf a dir --numeric-owner |dnl
|
||||
awk -vowner=$MYUID/$MYGID '@S|@2==owner {print "OK"; next} {print}'
|
||||
awk '@S|@2=="'"$MYUID/$MYGID"'" {print "OK"; next} {print}'
|
||||
tar $1 -vvf a dir |dnl
|
||||
awk -vowner=$MYUSR/$MYGRP '@S|@2==owner {print "OK"; next} {print}'
|
||||
awk '@S|@2=="'"$MYUSR/$MYGRP"'" {print "OK"; next} {print}'
|
||||
])
|
||||
|
||||
AT_TAR_CHECK([
|
||||
|
||||
@@ -29,6 +29,10 @@ AT_TAR_CHECK([
|
||||
orig_mode=3702
|
||||
mkdir d
|
||||
chmod $orig_mode d
|
||||
|
||||
mode=$(genfile --stat=mode.7777 d)
|
||||
test $mode = $orig_mode || AT_SKIP_TEST
|
||||
|
||||
genfile --file d/file
|
||||
tar -cf d.tar -C d .
|
||||
rm -rf d
|
||||
@@ -43,7 +47,7 @@ if test 700 = $mode; then
|
||||
else
|
||||
echo "CWD: mode changed: 700 != $mode"
|
||||
fi
|
||||
|
||||
|
||||
mkdir d2
|
||||
chmod 700 d2
|
||||
tar -C d2 --one-top-level=top -xpf d.tar
|
||||
|
||||
@@ -23,7 +23,7 @@ AT_KEYWORDS([sparse sparse06])
|
||||
|
||||
m4_define([check_pattern],[
|
||||
rm -rf out archive.tar smallsparse && mkdir out
|
||||
genfile --sparse --file smallsparse $1
|
||||
genfile --sparse --quiet --file smallsparse $1
|
||||
tar -cSf archive.tar smallsparse
|
||||
tar -xf archive.tar -C out
|
||||
cmp smallsparse out/smallsparse
|
||||
@@ -50,7 +50,6 @@ check_pattern([10M DEF 20M GHI 30M JKL 40M])
|
||||
|
||||
],
|
||||
[0],,
|
||||
[genfile: created file is not sparse
|
||||
],,,[posix])
|
||||
[],,,[posix])
|
||||
|
||||
AT_CLEANUP
|
||||
|
||||
Reference in New Issue
Block a user