diff options
Diffstat (limited to 'src/util/db2/test/run.test')
-rw-r--r-- | src/util/db2/test/run.test | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/src/util/db2/test/run.test b/src/util/db2/test/run.test index 462a9c2..c3922c8 100644 --- a/src/util/db2/test/run.test +++ b/src/util/db2/test/run.test @@ -31,6 +31,8 @@ main() dictsize=`wc -l < $DICT` + bindir=/bin/. + if [ $# -eq 0 ]; then for t in 1 2 3 4 5 6 7 8 9 10 11 12 13 20; do test$t @@ -141,15 +143,15 @@ test2() fi } -# Insert the programs in /bin with their paths as their keys. +# Insert the programs in $bindir with their paths as their keys. test3() { echo "Test 3: hash: small key, big data pairs" rm -f $TMP1 - (find /bin -type f -exec test -r {} \; -print | xargs cat) > $TMP1 + (find $bindir -type f -exec test -r {} \; -print | xargs cat) > $TMP1 for type in hash; do rm -f $TMP2 $TMP3 - for i in `find /bin -type f -exec test -r {} \; -print`; do + for i in `find $bindir -type f -exec test -r {} \; -print`; do echo p echo k$i echo D$i @@ -168,7 +170,7 @@ test3() echo " page size $psize" for type in btree; do rm -f $TMP2 $TMP3 - for i in `find /bin -type f -exec test -r {} \; -print`; do + for i in `find $bindir -type f -exec test -r {} \; -print`; do echo p echo k$i echo D$i @@ -185,7 +187,7 @@ test3() done echo "Test 3: recno: big data pairs" rm -f $TMP2 $TMP3 - find /bin -type f -exec test -r {} \; -print | + find $bindir -type f -exec test -r {} \; -print | awk '{ ++i; printf("p\nk%d\nD%s\ng\nk%d\n", i, $0, i); @@ -415,7 +417,12 @@ test8() printf("r\nkkey1\nr\nkkey2\n"); } }' > $TMP1 - $PROG btree $TMP1 + if $PROG btree $TMP1 ; then + true + else + echo "test8: btree tests failed" + exit 1 + fi # $PROG hash $TMP1 # No explicit test for success. } |