# Process this file with autom4te to create testsuite. -*- Autotest -*-
# Test suite for GNU tar.
-# Copyright (C) 2004 Free Software Foundation, Inc.
+# Copyright (C) 2004, 2006 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
AT_KEYWORDS([extract extract04])
AT_TAR_CHECK([
+AT_SORT_PREREQ
touch file1
mkdir directory
mkdir directory/subdirectory
tar -tf archive \
--exclude='./*1' \
--exclude='d*/*1' \
- --exclude='d*/s*/*2' | sort 2>/dev/null
+ --exclude='d*/s*/*2' | sort
],
[0],
[directory/
AT_KEYWORDS([incremental incr03 rename])
AT_TAR_CHECK([
+AT_SORT_PREREQ
mkdir directory
genfile --file=directory/x
genfile --file=directory/y
mv directory orig
echo Listing of archive.1
-tar -tf archive.1 | sort 2>/dev/null
+tar -tf archive.1 | sort
echo Listing of archive.2
-tar -tf archive.2 | sort 2>/dev/null
+tar -tf archive.2 | sort
echo Directory after first restore
tar -xf archive.1 -g db
-find directory | sort 2>/dev/null
+find directory | sort
echo Directory after second restore
tar -xf archive.2 -g db
-find directory | sort 2>/dev/null
+find directory | sort
],
[0],
[Listing of archive.1
AT_KEYWORDS([listed incremental listed02])
AT_TAR_CHECK([
-
+AT_SORT_PREREQ
echo Create directories
+
mkdir tart
sleep 1
mkdir tart/c0
# The above prints two lines to stderr announcing the new directories c0 and c1.
# Ensure that they appear in this script's stderr in sorted order.
-sort err 1>&2 2>/dev/null; rm -f err
+sort err 1>&2; rm -f err
sleep 1
echo Modifying filesystem
AT_KEYWORDS([pipe])
AT_TAR_CHECK([
+AT_SORT_PREREQ
+
mkdir directory
genfile --length 10240 --pattern zeros --file directory/file1
genfile --length 13 --file directory/file2
-tar cf archive directory|sort 2>/dev/null
+tar cf archive directory|sort
mv directory orig
-cat archive | tar xfv - | sort 2>/dev/null
+cat archive | tar xfv - | sort
echo "separator"
cmp orig/file1 directory/file1
echo "separator"
AT_KEYWORDS([incremental rename rename01])
AT_TAR_CHECK([
+AT_SORT_PREREQ
+
mkdir foo
genfile --file foo/file1
genfile --file foo/file2
AT_KEYWORDS([incremental rename rename02])
AT_TAR_CHECK([
+AT_SORT_PREREQ
mkdir foo
genfile --file foo/file1
genfile --file foo/file2
AT_KEYWORDS([incremental rename rename03 cyclic-rename])
AT_TAR_CHECK([
+AT_SORT_PREREQ
+
mkdir foo
genfile --file foo/file1
genfile --file foo/file2
AT_KEYWORDS([same-order same-order01])
AT_TAR_CHECK([
+AT_SORT_PREREQ
+
genfile -l 1024 -f file1
genfile -l 1024 -f file2
tar cf archive file1 file2
mkdir directory
tar -xf archive --same-order -C directory || exit 1
-ls directory|sort 2>/dev/null
+ls directory|sort
],
[0],
[file1
# Process this file with autom4te to create testsuite. -*- Autotest -*-
# Test suite for GNU tar.
-# Copyright (C) 2005 Free Software Foundation, Inc.
+# Copyright (C) 2005, 2006 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
AT_KEYWORDS([update])
AT_TAR_CHECK([
+AT_SORT_PREREQ
mkdir directory
genfile --length 10240 --pattern zeros --file directory/file1
genfile --length 10240 --pattern default --file directory/file2
echo separator
tar uf archive directory || exit 1
echo separator
-tar tf archive | sort 2>/dev/null || exit 1
+tar tf archive | sort || exit 1
],
[0],
[separator