diff regression/regression-tests.bash @ 236:093e0e9248bb stable-0-6-43

cleanup rfc822 embedded message code
author Carl Byington <carl@five-ten-sg.com>
date Sat, 12 Sep 2009 11:44:08 -0700
parents ed0cb66b23d4
children aa50c23a6935
line wrap: on
line diff
--- a/regression/regression-tests.bash	Fri Sep 11 12:59:24 2009 -0700
+++ b/regression/regression-tests.bash	Sat Sep 12 11:44:08 2009 -0700
@@ -22,9 +22,12 @@
     fn="$2"
     echo $fn
     ba=$(basename "$fn" .pst)
+    size=$(stat -c %s $fn)
     rm -rf output$n
-    mkdir output$n
-    $val ../src/pst2dii -f /usr/share/fonts/bitstream-vera/VeraMono.ttf -B "bates-" -o output$n -O $ba.mydii -d $fn.log $fn >$fn.dii.err 2>&1
+    if [ -z "$val" ] || [ $size -lt 10000000 ]; then
+        mkdir output$n
+        $val ../src/pst2dii -f /usr/share/fonts/bitstream-vera/VeraMono.ttf -B "bates-" -o output$n -O $ba.mydii -d $fn.log $fn >$fn.dii.err 2>&1
+    fi
 }
 
 
@@ -34,9 +37,12 @@
     fn="$2"
     echo $fn
     ba=$(basename "$fn" .pst)
+    size=$(stat -c %s $fn)
     rm -rf output$n
-    mkdir output$n
-    $val ../src/pst2ldif -d $ba.ldif.log -b 'o=ams-cc.com, c=US' -c 'inetOrgPerson' $fn >$ba.ldif.err 2>&1
+    if [ -z "$val" ] || [ $size -lt 10000000 ]; then
+        mkdir output$n
+        $val ../src/pst2ldif -d $ba.ldif.log -b 'o=ams-cc.com, c=US' -c 'inetOrgPerson' $fn >$ba.ldif.err 2>&1
+    fi
 }
 
 
@@ -46,18 +52,20 @@
     fn="$2"
     echo $fn
     ba=$(basename "$fn" .pst)
+    size=$(stat -c %s $fn)
     jobs=""
-    [ -n "$val" ]              && jobs="-j 0"
-    [ "$regression" == "yes" ] && jobs="-j 0"
+    [ -n "$val" ] && jobs="-j 0"
     rm -rf output$n
-    mkdir output$n
-    if [ "$regression" == "yes" ]; then
-        $val ../src/readpst $jobs -te -r -D -cv -o output$n $fn >$ba.err 2>&1
-    else
-        #val ../src/readpst $jobs -r -D -cv -o output$n            $fn
-        $val ../src/readpst $jobs -r -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1
-        #$val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1
-        #../src/getidblock -p $fn 0 >$ba.fulldump
+    if [ -z "$val" ] || [ $size -lt 10000000 ]; then
+        mkdir output$n
+        if [ "$regression" == "yes" ]; then
+            $val ../src/readpst $jobs -te -r -cv -o output$n $fn >$ba.err 2>&1
+        else
+            #val ../src/readpst $jobs -r -D -cv -o output$n            $fn
+            $val ../src/readpst $jobs -te -r -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1
+            #$val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1
+            #../src/getidblock -p $fn 0 >$ba.fulldump
+        fi
     fi
 }
 
@@ -70,14 +78,15 @@
 
 rm -rf output* *.err *.log
 
+v="valgrind --leak-check=full"
+val=""
+
 func="dopst"
 [ "$1" == "pst"  ] && func="dopst"
+[ "$1" == "pstv" ] && func="dopst" && val=$v
 [ "$1" == "ldif" ] && func="doldif"
 [ "$1" == "dii"  ] && func="dodii"
 
-val="valgrind --leak-check=full"
-val=""
-
 regression=""
 [ "$2" == "reg" ] && regression="yes"
 [ "$regression" == "yes" ] && val=""