aboutsummaryrefslogtreecommitdiff
path: root/tests/tar.test
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2016-03-02 13:49:47 -0600
committerRob Landley <rob@landley.net>2016-03-02 13:49:47 -0600
commit9ef6fbfc2bdc32be2a94040337f9b7fef5c18554 (patch)
tree89865db1da022b887692efc8991c3793ff1ee524 /tests/tar.test
parent7ae108f7c9d0845d8f7759ebeeb1b98a11ef8ceb (diff)
downloadtoybox-9ef6fbfc2bdc32be2a94040337f9b7fef5c18554.tar.gz
Try to consistently print command name at the start of each test.
Diffstat (limited to 'tests/tar.test')
-rwxr-xr-xtests/tar.test8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/tar.test b/tests/tar.test
index 5b10b014..034b7a3b 100755
--- a/tests/tar.test
+++ b/tests/tar.test
@@ -42,7 +42,7 @@ mkdir -p dir/dir1 dir/dir2 dir/dir3 dir/dir4
echo "This is testdata" > dir/dir1/file; echo "Dont exclude me" > dir/dir3/file1 ;
echo "Exclude me" > dir/dir3/file2 ; echo "YO" > dir/dir4/file1 ; echo "Hello" >dir/dir4/file2; echo "Dont" > dir/dir2/file1
echo -ne "dir/dir4\ndir/dir3/file2\n" > exclude_file
-testing "Creating tar with files excluded : -X" "tar -czf dir.tgz dir/ -X exclude_file ; rm -rf dir ; tar -tf dir.tgz | sort; rm -rf dir.tgz " "dir/\ndir/dir1/\ndir/dir1/file\ndir/dir2/\ndir/dir2/file1\ndir/dir3/\ndir/dir3/file1\n" "" ""
+testing "tar create with files excluded : -X" "tar -czf dir.tgz dir/ -X exclude_file ; rm -rf dir ; tar -tf dir.tgz | sort; rm -rf dir.tgz " "dir/\ndir/dir1/\ndir/dir1/file\ndir/dir2/\ndir/dir2/file1\ndir/dir3/\ndir/dir3/file1\n" "" ""
rm -rf exclude_file
#Creating nested directory
@@ -55,7 +55,7 @@ testing "tar with pattern --exclude" "tar --exclude=dir/dir3/* -czf dir.tgz dir/
mkdir dir/dir1 -p
echo "This is testdata" > dir/dir1/file
mkdir temp
-testing "Extraction with -C Dir" "tar -czf dir.tgz dir/ ;rm -rf dir ;tar -xf dir.tgz -C temp/ ; [ -e temp/dir ] && echo 'yes' ; rm -rf dir dir.tgz" "yes\n" "" ""
+testing "tar extract with -C Dir" "tar -czf dir.tgz dir/ ;rm -rf dir ;tar -xf dir.tgz -C temp/ ; [ -e temp/dir ] && echo 'yes' ; rm -rf dir dir.tgz" "yes\n" "" ""
rm -rf temp
#Creating nested directory
@@ -63,14 +63,14 @@ mkdir dir/dir1 -p ; mkdir dir/dir2 ; mkdir dir/dir3 ; mkdir dir/dir4 ; mkdir t
echo "dir1/file" > dir/dir1/file ; echo "temp_dir/file" > temp_dir/file
echo "dir3/file1" > dir/dir3/file1 ; echo "dir3/file2" > dir/dir3/file2 ; echo "YO" > dir/dir4/file1 ; echo "Hello" >dir/dir4/file2; echo "dir2/file1" > dir/dir2/file1
echo "temp_dir/file" > exclude_file
-testing "Creating tar extra files/directory included : -T" "tar -czf dir.tgz dir/ -T exclude_file ; rm -rf dir ; tar -tf dir.tgz | sort; rm -rf dir.tgz " "dir/\ndir/dir1/\ndir/dir1/file\ndir/dir2/\ndir/dir2/file1\ndir/dir3/\ndir/dir3/file1\ndir/dir3/file2\ndir/dir4/\ndir/dir4/file1\ndir/dir4/file2\ntemp_dir/file\n" "" ""
+testing "tar create with extra files/directory included : -T" "tar -czf dir.tgz dir/ -T exclude_file ; rm -rf dir ; tar -tf dir.tgz | sort; rm -rf dir.tgz " "dir/\ndir/dir1/\ndir/dir1/file\ndir/dir2/\ndir/dir2/file1\ndir/dir3/\ndir/dir3/file1\ndir/dir3/file2\ndir/dir4/\ndir/dir4/file1\ndir/dir4/file2\ntemp_dir/file\n" "" ""
rm -rf exclude_file
rm -rf temp_dir
#Creating dir
mkdir dir/dir1 -p
echo "Inside dir/dir1" > dir/dir1/file ; echo "Hello Inside dir" > dir/file
-testing "Extraction on STDOUT : -O" " tar -czf dir.tgz dir/ ; rm -rf dir ; tar -xf dir.tgz -O ; [ -e 'Inside dir/dir1/\nHello Inside dir\n' ] && echo 'yes'; rm -rf dir.tgz " "" "" ""
+testing "tar extract to STDOUT : -O" " tar -czf dir.tgz dir/ ; rm -rf dir ; tar -xf dir.tgz -O ; [ -e 'Inside dir/dir1/\nHello Inside dir\n' ] && echo 'yes'; rm -rf dir.tgz " "" "" ""
#Creating short filename
f="filename_with_100_chars_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"