tests: handle compilation errors when nitc succeed but gcc failed
authorJean Privat <jean@pryen.org>
Tue, 7 Jul 2009 15:21:06 +0000 (11:21 -0400)
committerJean Privat <jean@pryen.org>
Tue, 7 Jul 2009 15:21:06 +0000 (11:21 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>

tests/sav/base_closure_raf_alt15.fail
tests/sav/error_class_glob.fail
tests/tests.sh

index ff05281..7f85acf 100644 (file)
@@ -1 +1 @@
-./tests.sh: line 119: ./error_class_glob.bin: No such file or directory
+Compilation error
index 147e8cc..8fccfbd 100755 (executable)
@@ -103,7 +103,7 @@ for ii in "$@"; do
                if [ "$ERR" != 0 ]; then
                        echo -n "! "
                        cp "$ff.cmp.err" "$ff.res"
-               else
+               elif [ -x "./$ff.bin" ]; then
                        echo -n ". "
                        # Execute
                        if [ -f "$f.args" ]; then
@@ -130,6 +130,9 @@ for ii in "$@"; do
                        if [ -s "$ff.err" ]; then
                                cat "$ff.err" >> "$ff.res"
                        fi
+               else
+                       echo -n "! "
+                       echo "Compilation error" > "$ff.res"
                fi
 
                # Result