Commit 4b85f67d authored by Niels Möller's avatar Niels Möller

run-tests: Added (c) notice. Some whitespace cleanup.

parent 79f4ded0
#! /bin/sh
# Copyright (C) 2000, 2001, 2002, 2004, 2005, 2011, 2012 Niels Möller
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
failed=0
all=0
......@@ -13,7 +29,7 @@ fi
export srcdir
# When used in make rules, we sometimes get the filenames VPATH
# expanded, but usually not.
# expanded, but usually not.
find_program () {
case "$1" in
*/*)
......@@ -48,14 +64,14 @@ test_program () {
fi
case "$?" in
0)
echo PASS: $testname
echo PASS: $testname
all=`expr $all + 1`
;;
77)
echo SKIP: $testname
echo SKIP: $testname
;;
*)
echo FAIL: $testname
echo FAIL: $testname
failed=`expr $failed + 1`
all=`expr $all + 1`
;;
......@@ -74,7 +90,7 @@ do
testflags='-v'
;;
-*)
echo >&2 'Unknown option `'"$1'"
echo >&2 'Unknown option `'"$1'"
exit 1
;;
*)
......@@ -83,7 +99,7 @@ do
esac
shift
done
if [ $# -eq 0 ] ; then
for f in *-test; do test_program "./$f"; done
else
......@@ -105,4 +121,3 @@ if [ "x$debug" = xno ] ; then
fi
[ "$failed" -eq 0 ]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment