[cig-commits] [commit] master: update test script (2f6ee89)
cig_noreply at geodynamics.org
cig_noreply at geodynamics.org
Fri Dec 12 16:32:50 PST 2014
Repository : https://github.com/geodynamics/burnman
On branch : master
Link : https://github.com/geodynamics/burnman/compare/6111717707e0bd07c31d999c20c7a56db163ff48...916ee6acd98bd253c534a4b858b8d86ec62c3fd5
>---------------------------------------------------------------
commit 2f6ee894c6129a9a01e30b4f14aff14f0d1eb441
Author: Timo Heister <timo.heister at gmail.com>
Date: Fri Dec 12 16:07:42 2014 -0800
update test script
>---------------------------------------------------------------
2f6ee894c6129a9a01e30b4f14aff14f0d1eb441
test.sh | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/test.sh b/test.sh
index 96f4e60..78559a6 100755
--- a/test.sh
+++ b/test.sh
@@ -4,6 +4,7 @@ fulldir=`pwd`
function testit {
t=$1
+fulldir=$2
#echo "*** testing $t ..."
(python <<EOF
import matplotlib as m
@@ -29,11 +30,11 @@ else
sed -i'' '/cannot be converted with the encoding. Glyph may be wrong/d' $t.tmp #remove font warning crap
sed -i'' '/time old .* time new/d' $t.tmp #remove timing from tests/debye.py
- (numdiff -r 1e-6 -s ' \t\n[]' -a 1e-6 -q $t.tmp ../misc/ref/$t.out >/dev/null && rm $t.tmp && echo " $t ... ok"
+ (numdiff -r 1e-6 -s ' \t\n[]' -a 1e-6 -q $t.tmp $fulldir/misc/ref/$t.out >/dev/null && rm $t.tmp && echo " $t ... ok"
) || {
echo "! $t ... FAIL";
- echo "Check: `readlink -f $t.tmp` `readlink -f ../misc/ref/$t.out`";
- numdiff -r 1e-6 -s ' \t\n[]' -a 1e-6 $t.tmp ../misc/ref/$t.out | head
+ echo "Check: `readlink -f $t.tmp` `readlink -f $fulldir/misc/ref/$t.out`";
+ numdiff -r 1e-6 -s ' \t\n[]' -a 1e-6 $t.tmp $fulldir/misc/ref/$t.out | head
}
fi
@@ -62,7 +63,7 @@ python gen_doc.py >/dev/null || exit 1
cd benchmarks
for test in `ls *.py`
do
- testit $test
+ testit $test $fulldir
done
cd ..
cd ..
@@ -79,7 +80,7 @@ do
[ $test == "example_compare_enstpyro.py" ] && echo " *** skipping $test !" && continue
[ $test == "example_partition_coef.py" ] && echo " *** skipping $test !" && continue
- testit $test
+ testit $test $fulldir
done
cd ..
@@ -90,10 +91,10 @@ for test in `ls paper*.py`
do
[ $test == "paper_opt_pv_old.py" ] && echo " *** skipping $test !" && continue
- testit $test
+ testit $test $fulldir
done
-testit table.py
+testit table.py $fulldir
cd ..
echo " done"
More information about the CIG-COMMITS
mailing list