Mercurial > libpst
comparison 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 |
comparison
equal
deleted
inserted
replaced
235:9d6bb722d0fe | 236:093e0e9248bb |
---|---|
20 { | 20 { |
21 n="$1" | 21 n="$1" |
22 fn="$2" | 22 fn="$2" |
23 echo $fn | 23 echo $fn |
24 ba=$(basename "$fn" .pst) | 24 ba=$(basename "$fn" .pst) |
25 size=$(stat -c %s $fn) | |
25 rm -rf output$n | 26 rm -rf output$n |
26 mkdir output$n | 27 if [ -z "$val" ] || [ $size -lt 10000000 ]; then |
27 $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 | 28 mkdir output$n |
29 $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 | |
30 fi | |
28 } | 31 } |
29 | 32 |
30 | 33 |
31 function doldif() | 34 function doldif() |
32 { | 35 { |
33 n="$1" | 36 n="$1" |
34 fn="$2" | 37 fn="$2" |
35 echo $fn | 38 echo $fn |
36 ba=$(basename "$fn" .pst) | 39 ba=$(basename "$fn" .pst) |
40 size=$(stat -c %s $fn) | |
37 rm -rf output$n | 41 rm -rf output$n |
38 mkdir output$n | 42 if [ -z "$val" ] || [ $size -lt 10000000 ]; then |
39 $val ../src/pst2ldif -d $ba.ldif.log -b 'o=ams-cc.com, c=US' -c 'inetOrgPerson' $fn >$ba.ldif.err 2>&1 | 43 mkdir output$n |
44 $val ../src/pst2ldif -d $ba.ldif.log -b 'o=ams-cc.com, c=US' -c 'inetOrgPerson' $fn >$ba.ldif.err 2>&1 | |
45 fi | |
40 } | 46 } |
41 | 47 |
42 | 48 |
43 function dopst() | 49 function dopst() |
44 { | 50 { |
45 n="$1" | 51 n="$1" |
46 fn="$2" | 52 fn="$2" |
47 echo $fn | 53 echo $fn |
48 ba=$(basename "$fn" .pst) | 54 ba=$(basename "$fn" .pst) |
55 size=$(stat -c %s $fn) | |
49 jobs="" | 56 jobs="" |
50 [ -n "$val" ] && jobs="-j 0" | 57 [ -n "$val" ] && jobs="-j 0" |
51 [ "$regression" == "yes" ] && jobs="-j 0" | |
52 rm -rf output$n | 58 rm -rf output$n |
53 mkdir output$n | 59 if [ -z "$val" ] || [ $size -lt 10000000 ]; then |
54 if [ "$regression" == "yes" ]; then | 60 mkdir output$n |
55 $val ../src/readpst $jobs -te -r -D -cv -o output$n $fn >$ba.err 2>&1 | 61 if [ "$regression" == "yes" ]; then |
56 else | 62 $val ../src/readpst $jobs -te -r -cv -o output$n $fn >$ba.err 2>&1 |
57 #val ../src/readpst $jobs -r -D -cv -o output$n $fn | 63 else |
58 $val ../src/readpst $jobs -r -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 | 64 #val ../src/readpst $jobs -r -D -cv -o output$n $fn |
59 #$val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 | 65 $val ../src/readpst $jobs -te -r -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 |
60 #../src/getidblock -p $fn 0 >$ba.fulldump | 66 #$val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 |
67 #../src/getidblock -p $fn 0 >$ba.fulldump | |
68 fi | |
61 fi | 69 fi |
62 } | 70 } |
63 | 71 |
64 | 72 |
65 | 73 |
68 make || exit | 76 make || exit |
69 popd | 77 popd |
70 | 78 |
71 rm -rf output* *.err *.log | 79 rm -rf output* *.err *.log |
72 | 80 |
81 v="valgrind --leak-check=full" | |
82 val="" | |
83 | |
73 func="dopst" | 84 func="dopst" |
74 [ "$1" == "pst" ] && func="dopst" | 85 [ "$1" == "pst" ] && func="dopst" |
86 [ "$1" == "pstv" ] && func="dopst" && val=$v | |
75 [ "$1" == "ldif" ] && func="doldif" | 87 [ "$1" == "ldif" ] && func="doldif" |
76 [ "$1" == "dii" ] && func="dodii" | 88 [ "$1" == "dii" ] && func="dodii" |
77 | |
78 val="valgrind --leak-check=full" | |
79 val="" | |
80 | 89 |
81 regression="" | 90 regression="" |
82 [ "$2" == "reg" ] && regression="yes" | 91 [ "$2" == "reg" ] && regression="yes" |
83 [ "$regression" == "yes" ] && val="" | 92 [ "$regression" == "yes" ] && val="" |
84 | 93 |