X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Ftar;a=blobdiff_plain;f=tests%2Fremfiles05c.at;fp=tests%2Fremfiles06.at;h=a01b0920237f9613ac60c0b9ef4ab109848e83f8;hp=3c3dbf4e11b44f50fc98f0c42d16237a35806bab;hb=3125d311e17c91da85de3bca326cf485523d78a0;hpb=74ce228f6df956e6b7be9fd4f993bada4b7ea645 diff --git a/tests/remfiles06.at b/tests/remfiles05c.at similarity index 65% rename from tests/remfiles06.at rename to tests/remfiles05c.at index 3c3dbf4..a01b092 100644 --- a/tests/remfiles06.at +++ b/tests/remfiles05c.at @@ -15,39 +15,39 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Description: There was a leftover call to chdir in name_next_elt() in -# tar 1.26. After commit e3d28d84 this call would confuse the tar_getcwd -# function. -# Reported by: Nathan Stratton Treadway -# References: <20130924145657.GM32256@shire.ontko.com>, -# http://lists.gnu.org/archive/html/bug-tar/2013-09/msg00045.html +# Description: ensure tar correctly respects -C option when deleting +# files due to the --remove-files option. +# +# This case checks the use of two relative-path -C options, +# in --append mode. +# -AT_SETUP([remove with two -C]) -AT_KEYWORDS([remove-files remfiles06]) +AT_SETUP([remove-files with -C:rel,rel in -r mode]) +AT_KEYWORDS([create append remove-files remfiles05 remfiles05c]) AT_TAR_CHECK([ AT_SORT_PREREQ -mkdir tartest -cd tartest mkdir foo -echo foo/file > foo/file mkdir bar +echo file > file +echo foo/file > foo/file echo bar/file > bar/file +tar -cf foo.tar -C foo file -C ../bar file decho A -find|sort - +find . | sort decho B -tar -cvf ../foo.tar --remove-files -C foo file -C ../bar file - +tar -rvf foo.tar --remove-files -C foo file -C ../bar file decho C -find|sort +find . | sort ], [0], [A . ./bar ./bar/file +./file ./foo +./foo.tar ./foo/file B file @@ -55,7 +55,9 @@ file C . ./bar +./file ./foo +./foo.tar ], [A B