aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2016-03-23 03:44:51 -0500
committerRob Landley <rob@landley.net>2016-03-23 03:44:51 -0500
commit1ffa7f45eb4fe3b73f94e69c929ad311d9c44b81 (patch)
tree2e4607cd74dfeb942fa65bf7c5cf23d07dc1d066
parentb52f642472af932e382342c4faf30643b91f6be1 (diff)
downloadtoybox-1ffa7f45eb4fe3b73f94e69c929ad311d9c44b81.tar.gz
Fix bzcat.test (as noted by Andy Chu), wean tests off $TOPDIR and supply $FILES
instead, move tests/blkid into tests/files/blkid.
-rwxr-xr-xscripts/test.sh3
-rwxr-xr-xtests/blkid.test2
-rwxr-xr-xtests/bzcat.test2
-rw-r--r--tests/files/blkid/cramfs.bz2 (renamed from tests/blkid/cramfs.bz2)bin121 -> 121 bytes
-rw-r--r--tests/files/blkid/ext2.bz2 (renamed from tests/blkid/ext2.bz2)bin2396 -> 2396 bytes
-rw-r--r--tests/files/blkid/ext3.bz2 (renamed from tests/blkid/ext3.bz2)bin4132 -> 4132 bytes
-rw-r--r--tests/files/blkid/ext4.bz2 (renamed from tests/blkid/ext4.bz2)bin2491 -> 2491 bytes
-rw-r--r--tests/files/blkid/f2fs.bz2 (renamed from tests/blkid/f2fs.bz2)bin634 -> 634 bytes
-rw-r--r--tests/files/blkid/minix.bz2 (renamed from tests/blkid/minix.bz2)bin157 -> 157 bytes
-rw-r--r--tests/files/blkid/msdos.bz2 (renamed from tests/blkid/msdos.bz2)bin288 -> 288 bytes
-rw-r--r--tests/files/blkid/ntfs.bz2 (renamed from tests/blkid/ntfs.bz2)bin35854 -> 35854 bytes
-rw-r--r--tests/files/blkid/reiser3.bz2 (renamed from tests/blkid/reiser3.bz2)bin329 -> 329 bytes
-rw-r--r--tests/files/blkid/squashfs.bz2 (renamed from tests/blkid/squashfs.bz2)bin158 -> 158 bytes
-rw-r--r--tests/files/blkid/vfat.bz2 (renamed from tests/blkid/vfat.bz2)bin291 -> 291 bytes
-rw-r--r--tests/files/blkid/xfs.bz2 (renamed from tests/blkid/xfs.bz2)bin437 -> 437 bytes
-rwxr-xr-xtests/fstype.test2
16 files changed, 5 insertions, 4 deletions
diff --git a/scripts/test.sh b/scripts/test.sh
index 0c3d7aaf..1337c529 100755
--- a/scripts/test.sh
+++ b/scripts/test.sh
@@ -1,6 +1,7 @@
#!/bin/bash
-[ -z "$TOPDIR" ] && TOPDIR="$(pwd)"
+TOPDIR="$PWD"
+FILES="$PWD"/tests/files
trap 'kill $(jobs -p) 2>/dev/null; exit 1' INT
diff --git a/tests/blkid.test b/tests/blkid.test
index c99b2a42..d3bf6a1f 100755
--- a/tests/blkid.test
+++ b/tests/blkid.test
@@ -4,7 +4,7 @@
#testing "name" "command" "result" "infile" "stdin"
-BDIR="$TOPDIR/tests/blkid"
+BDIR="$FILES/blkid"
bzcat "$BDIR"/squashfs.bz2 > temp.img
testing "file" "blkid temp.img" 'temp.img: TYPE="squashfs"\n' "" ""
diff --git a/tests/bzcat.test b/tests/bzcat.test
index ef1b07f5..f57a2f88 100755
--- a/tests/bzcat.test
+++ b/tests/bzcat.test
@@ -7,7 +7,7 @@
#testing "name" "command" "result" "infile" "stdin"
testing "overflow" \
- 'bzcat "$TOPDIR/files/bzcat/overflow.bz2" >/dev/null 2>/dev/null;
+ 'bzcat "$FILES/bzcat/overflow.bz2" >/dev/null 2>/dev/null ;
[ $? -eq 1 ] && echo good' "good\n" "" ""
echo "hello" > file
diff --git a/tests/blkid/cramfs.bz2 b/tests/files/blkid/cramfs.bz2
index 37438fe8..37438fe8 100644
--- a/tests/blkid/cramfs.bz2
+++ b/tests/files/blkid/cramfs.bz2
Binary files differ
diff --git a/tests/blkid/ext2.bz2 b/tests/files/blkid/ext2.bz2
index e27c4d76..e27c4d76 100644
--- a/tests/blkid/ext2.bz2
+++ b/tests/files/blkid/ext2.bz2
Binary files differ
diff --git a/tests/blkid/ext3.bz2 b/tests/files/blkid/ext3.bz2
index be7f11f2..be7f11f2 100644
--- a/tests/blkid/ext3.bz2
+++ b/tests/files/blkid/ext3.bz2
Binary files differ
diff --git a/tests/blkid/ext4.bz2 b/tests/files/blkid/ext4.bz2
index a8314f91..a8314f91 100644
--- a/tests/blkid/ext4.bz2
+++ b/tests/files/blkid/ext4.bz2
Binary files differ
diff --git a/tests/blkid/f2fs.bz2 b/tests/files/blkid/f2fs.bz2
index 4111e876..4111e876 100644
--- a/tests/blkid/f2fs.bz2
+++ b/tests/files/blkid/f2fs.bz2
Binary files differ
diff --git a/tests/blkid/minix.bz2 b/tests/files/blkid/minix.bz2
index b2f022e0..b2f022e0 100644
--- a/tests/blkid/minix.bz2
+++ b/tests/files/blkid/minix.bz2
Binary files differ
diff --git a/tests/blkid/msdos.bz2 b/tests/files/blkid/msdos.bz2
index 26c9b665..26c9b665 100644
--- a/tests/blkid/msdos.bz2
+++ b/tests/files/blkid/msdos.bz2
Binary files differ
diff --git a/tests/blkid/ntfs.bz2 b/tests/files/blkid/ntfs.bz2
index b654ecd6..b654ecd6 100644
--- a/tests/blkid/ntfs.bz2
+++ b/tests/files/blkid/ntfs.bz2
Binary files differ
diff --git a/tests/blkid/reiser3.bz2 b/tests/files/blkid/reiser3.bz2
index b2adfc85..b2adfc85 100644
--- a/tests/blkid/reiser3.bz2
+++ b/tests/files/blkid/reiser3.bz2
Binary files differ
diff --git a/tests/blkid/squashfs.bz2 b/tests/files/blkid/squashfs.bz2
index 2f1b7937..2f1b7937 100644
--- a/tests/blkid/squashfs.bz2
+++ b/tests/files/blkid/squashfs.bz2
Binary files differ
diff --git a/tests/blkid/vfat.bz2 b/tests/files/blkid/vfat.bz2
index 1df8b89a..1df8b89a 100644
--- a/tests/blkid/vfat.bz2
+++ b/tests/files/blkid/vfat.bz2
Binary files differ
diff --git a/tests/blkid/xfs.bz2 b/tests/files/blkid/xfs.bz2
index a7571960..a7571960 100644
--- a/tests/blkid/xfs.bz2
+++ b/tests/files/blkid/xfs.bz2
Binary files differ
diff --git a/tests/fstype.test b/tests/fstype.test
index cc7a6206..3df26b19 100755
--- a/tests/fstype.test
+++ b/tests/fstype.test
@@ -4,7 +4,7 @@
#testing "name" "command" "result" "infile" "stdin"
-BDIR="$TOPDIR/tests/blkid"
+BDIR="$FILES/blkid"
bzcat "$BDIR"/squashfs.bz2 > temp.img
testing "file" "fstype temp.img" 'squashfs\n' "" ""