aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunichi Uekawa <dancer@netfort.gr.jp>2008-08-11 23:58:12 +0900
committerJunichi Uekawa <dancer@netfort.gr.jp>2008-08-11 23:58:12 +0900
commit4e6812f6b926d0f6560b67846becc2c546db1ab0 (patch)
tree87437804edee26b489db43f75ce56eb94e1623dd
parentf4494dca6f9d64baf4757b45f2d69da2a752b23b (diff)
downloadpbuilder-4e6812f6b926d0f6560b67846becc2c546db1ab0.tar
pbuilder-4e6812f6b926d0f6560b67846becc2c546db1ab0.tar.gz
change output of testsuite to be less verbose.
-rw-r--r--testlib.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/testlib.sh b/testlib.sh
index 459c630..533fd94 100644
--- a/testlib.sh
+++ b/testlib.sh
@@ -11,8 +11,7 @@ TESTLIB_TESTS=0
testlib_echo() {
case "$1" in
OK)
- shift
- echo "[OK ]" "$@" >&2
+ # no output is probably good.
;;
FAIL)
shift
@@ -24,10 +23,11 @@ testlib_echo() {
}
testlib_summary() {
- echo "Ran ${TESTLIB_TESTS} tests and ${TESTLIB_FAILS} failed"
+ echo "$0: Ran ${TESTLIB_TESTS} tests and $((TESTLIB_TESTS - TESTLIB_FAILS)) succeeded, ${TESTLIB_FAILS} failed"
if [ $TESTLIB_FAILS != 0 ]; then
echo '================='
echo 'Testsuite FAILED!'
+ echo " $0"
echo '================='
exit 1
fi
@@ -69,6 +69,7 @@ expect_output() {
}
# Write your functions test_xxxx and call them at the end with their expected result code:
+# . ./testlib.sh
# expect_success test_success
# expect_success test_fail
# expect_success test_options "hello world"