]> git.donarmstrong.com Git - biopieces.git/blobdiff - bp_test/lib/test.sh
fixing usearch upgrade
[biopieces.git] / bp_test / lib / test.sh
index 68e3825ed62ff155e36dc75b635617058612b56a..7ce41900d12068649fdf92320f6110f779c17398 100755 (executable)
@@ -3,8 +3,8 @@
 bp=`basename $0 | sed s/^test_//`
 in="$BP_DIR/bp_test/in/$bp.in"
 out="$BP_DIR/bp_test/out/$bp.out"
-tmp="$BP_TMP/$bp.out"
-tmp_dir="$BP_TMP/test_tmp"
+tmp="$BP_TMP/$USER.$bp.out"
+tmp_dir="$BP_TMP/$USER.test_tmp"
 log_file="$BP_TMP/$USER.test.log"
 
 # Function to run a given command (verbose).
@@ -14,6 +14,7 @@ function run
 
     msg="${command/$BP_DIR/\$BP_DIR}"
     msg="${msg//$BP_TMP/\$BP_TMP}"
+    msg="${msg/$BP_DIR/\$BP_DIR}"
 
     echo -n "Testing $msg ... "
     eval $command > /dev/null 2>&1
@@ -76,8 +77,8 @@ function assert_no_diff_dir
         return
     fi
 
-    local src_cksum=`find $src_dir -type f | xargs cat | cksum`
-    local dst_cksum=`find $dst_dir -type f | xargs cat | cksum`
+    local src_cksum=`find $src_dir -type f | grep -v "\.svn" | sort | xargs cat | cksum`
+    local dst_cksum=`find $dst_dir -type f | grep -v "\.svn" | sort | xargs cat | cksum`
 
     if [ "$src_cksum" == "$dst_cksum" ]; then
         echo_green "OK"