diff options
author | rubidium <rubidium@openttd.org> | 2014-09-21 17:22:50 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2014-09-21 17:22:50 +0000 |
commit | 8415a159991acd2263607b7d1ed4bfeed802a316 (patch) | |
tree | 395a78693c7cf2a5f73716da0e54fa51eaca9d91 /bin | |
parent | d87e20d6f4241c31cb0571d264fc4c8290537679 (diff) | |
download | openttd-8415a159991acd2263607b7d1ed4bfeed802a316.tar.xz |
(svn r26898) -Fix: hopefully make regression under MinGW work again
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ai/regression/run.sh | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/bin/ai/regression/run.sh b/bin/ai/regression/run.sh index adf4dba0c..d47a664ea 100755 --- a/bin/ai/regression/run.sh +++ b/bin/ai/regression/run.sh @@ -30,7 +30,7 @@ fi ret=0 for tst in $tests; do - echo "running $tst" + echo -n "Running $tst... " # Make sure that only one info.nut is present for each test run. Otherwise openttd gets confused. cp ai/regression/regression_info.nut $tst/info.nut @@ -47,26 +47,19 @@ for tst in $tests; do fi if [ -z "$gdb" ]; then - # Ugly newline insertion, but it says /bin/sh above ... - res="$res -`diff -ub $tst/result.txt tmp.regression`" + res="`diff -ub $tst/result.txt tmp.regression`" + if [ -z "$res" ]; then + echo "passed!" + else + echo "failed! Difference:" + echo "$res" + ret=1 + fi fi rm $tst/info.nut done -if [ -z "$gdb" ]; then - if [ -z "$res" ]; then - echo "Regression test passed!" - else - echo "Regression test failed! Difference:" - echo "$res" - ret=1 - fi - echo "" - echo "Regression test done" -fi - if [ -f scripts/game_start.scr.regression ]; then mv scripts/game_start.scr.regression scripts/game_start.scr fi |