summaryrefslogtreecommitdiff
path: root/tests/run.sh
diff options
context:
space:
mode:
authorKarel Zak <kzak@redhat.com>2007-01-04 14:23:48 +0100
committerKarel Zak <kzak@redhat.com>2007-01-04 14:23:48 +0100
commite83446da1a3f626920d5e65d4f78651581765b61 (patch)
tree56880fa701f6f1e78bb65808f86f859f9bd93d84 /tests/run.sh
parent61d9d2ff1cb0e28e2b88099bbc5b919fa5004fce (diff)
downloadutil-linux-old-e83446da1a3f626920d5e65d4f78651581765b61.tar.gz
tests: add basic infrastructure for regression tests
The patch adds tests/ directory with simple regression tests infrastructure. Also, it adds the "ts-mount-paths" test that testing if all defined paths (fstab, mtab, locks) are still same. Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'tests/run.sh')
-rwxr-xr-xtests/run.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/run.sh b/tests/run.sh
new file mode 100755
index 00000000..b4ca51b5
--- /dev/null
+++ b/tests/run.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+. commands.sh
+
+echo
+echo "------------------ Utils-linux-ng regression tests ------------------"
+echo
+
+res=0
+count=0
+for ts in `ls ts-*`; do
+ $TS_TOPDIR/$ts
+ res=$(( $res + $? ))
+ count=$(( $count + 1 ))
+done
+
+echo
+echo "---------------------------------------------------------------------"
+if [ $res -eq 0 ]; then
+ echo " All $count tests PASSED"
+else
+ echo " $res tests of $count FAILED"
+fi
+echo "---------------------------------------------------------------------"
+