]> Dogcows Code - chaz/tar/blob - tests/extrac17.at
Update copyright years.
[chaz/tar] / tests / extrac17.at
1 # Process this file with autom4te to create testsuite. -*- Autotest -*-
2 #
3 # Test suite for GNU tar.
4 # Copyright 2010, 2013-2014 Free Software Foundation, Inc.
5
6 # This file is part of GNU tar.
7
8 # GNU tar is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 3 of the License, or
11 # (at your option) any later version.
12
13 # GNU tar is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
17
18 # You should have received a copy of the GNU General Public License
19 # along with this program. If not, see <http://www.gnu.org/licenses/>.
20
21 AT_SETUP([name matching/transformation ordering])
22 AT_KEYWORDS([extract extrac17])
23
24 # Description: Tar 1.24 changed the ordering of name matching and
25 # name transformation so that the former saw already transformed
26 # file names (see commit 9c194c99 and exclude06.at). This reverted
27 # ordering made it impossible to match file names in certain cases.
28 # In particular, the testcase below would not extract anything.
29 #
30 # Reported-by: "Gabor Z. Papp" <gzp@papp.hu>
31 # References: <x6r5fd9jye@gzp>, <20101026175126.29028@Pirx.gnu.org.ua>
32 # http://lists.gnu.org/archive/html/bug-tar/2010-10/msg00047.html
33
34 AT_TAR_CHECK([
35 mkdir dir dir/subdir1 dir/subdir2 out
36 genfile --file dir/subdir1/file1
37 genfile --file dir/subdir2/file2
38
39 tar cf dir.tar dir
40
41 tar -x -v -f dir.tar -C out --strip-components=2 --warning=no-timestamp \
42 dir/subdir1/
43 ],
44 [0],
45 [dir/subdir1/file1
46 ])
47
48 AT_CLEANUP
This page took 0.042918 seconds and 5 git commands to generate.