summaryrefslogtreecommitdiffstats
path: root/run-tests.sh
diff options
context:
space:
mode:
authorAnand Avati <avati@redhat.com>2013-09-15 19:56:25 -0700
committerAnand Avati <avati@redhat.com>2013-09-20 21:12:39 -0700
commit7f608415063f04a1035bfe7d0f8ddfb9f0215e5c (patch)
tree547deabfc9053525165b1d9719640f715aac0e24 /run-tests.sh
parent2e4064fe08e929fb4db30ae63c5cd404ab2d8b20 (diff)
tests: take regression tests out of autotools
make run-tests.sh "location independent" and replace 'make install' with cpio in glusterfs.spec.in Change-Id: I140473c7f558e1e0af93a863b79098ced516a76b BUG: 764966 Signed-off-by: Anand Avati <avati@redhat.com> Reviewed-on: http://review.gluster.org/5986 Reviewed-by: Harshavardhana <harsha@harshavardhana.net> Tested-by: Gluster Build System <jenkins@build.gluster.com>
Diffstat (limited to 'run-tests.sh')
-rwxr-xr-xrun-tests.sh30
1 files changed, 30 insertions, 0 deletions
diff --git a/run-tests.sh b/run-tests.sh
new file mode 100755
index 00000000000..128404ed5e7
--- /dev/null
+++ b/run-tests.sh
@@ -0,0 +1,30 @@
+#!/bin/bash
+# Copyright (c) 2013 Red Hat, Inc. <http://www.redhat.com>
+#
+
+function _init()
+{
+ regression_testsdir=$(dirname $0);
+
+ if [ ! -f ${regression_testsdir}/tests/include.rc ]; then
+ echo "Seems like GlusterFS quality tests are corrupted..aborting!!"
+ exit 1
+ fi
+}
+
+function main()
+{
+ if [ $# -lt 1 ]; then
+ echo "Running all the regression test cases"
+ prove -rf --timer ${regression_testsdir}/tests;
+ else
+ ## TODO
+ echo "Running single regression test.."
+ echo "WARNING: yet to be implemented.. exiting safely"
+ exit 0
+ #export DEBUG=1;
+ #echo "Automatically setting up DEBUG=1 for this test $1";
+ fi
+}
+
+_init "$@" && main "$@"