summaryrefslogtreecommitdiff
path: root/qpid/cpp/src/tests/ais_check
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2008-06-26 18:12:12 +0000
committerAlan Conway <aconway@apache.org>2008-06-26 18:12:12 +0000
commit8eafbcc7821ea6a6a6976e06fe2c6810c9767e2b (patch)
tree2439a2a981657e4b73d0e1c8c5ca6f12323f15a9 /qpid/cpp/src/tests/ais_check
parent05194376a430592ddabb2657431ecc4442c3ab45 (diff)
downloadqpid-python-8eafbcc7821ea6a6a6976e06fe2c6810c9767e2b.tar.gz
Consolidated cluster tests in cluster_test.cpp
Improvements to BrokerFixture for testing. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@671969 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/ais_check')
-rwxr-xr-xqpid/cpp/src/tests/ais_check13
1 files changed, 8 insertions, 5 deletions
diff --git a/qpid/cpp/src/tests/ais_check b/qpid/cpp/src/tests/ais_check
index f16480b7f0..e2d53b5870 100755
--- a/qpid/cpp/src/tests/ais_check
+++ b/qpid/cpp/src/tests/ais_check
@@ -23,11 +23,14 @@ EOF
exit 0; # A warning, not a failure.
fi
+# Execute command with the ais group set.
+with_ais_group() {
+ id -nG | grep '\<ais\>' >/dev/null || { echo "You are not a member of the ais group."; exit 1; }
+ echo $* | newgrp ais
+}
+
# Run the tests
srcdir=`dirname $0`
-$srcdir/start_cluster 4
-./ais_test
-ret=$?
-$srcdir/stop_cluster
-exit $ret
+with_ais_group ./cluster_test || ERROR=1
+exit $ERROR