summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2012-05-09 20:27:35 +0000
committerAlan Conway <aconway@apache.org>2012-05-09 20:27:35 +0000
commitf445b483ed01e1c91d5af02c2b89b5f8658323b3 (patch)
tree1cd6d2d635a52f21396733fcfb707b63a1e755f2
parent7305e7862ec052faccf0a8b2bd3964cfacd18b7c (diff)
downloadqpid-python-f445b483ed01e1c91d5af02c2b89b5f8658323b3.tar.gz
NO-JIRA: Skip HA tests if required python tools are not available.
Backported from trunk r1335218 git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/0.16@1336378 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--qpid/cpp/src/tests/Makefile.am7
-rwxr-xr-xqpid/cpp/src/tests/run_ha_tests29
2 files changed, 33 insertions, 3 deletions
diff --git a/qpid/cpp/src/tests/Makefile.am b/qpid/cpp/src/tests/Makefile.am
index 7c0afc4a63..706c253ca2 100644
--- a/qpid/cpp/src/tests/Makefile.am
+++ b/qpid/cpp/src/tests/Makefile.am
@@ -150,7 +150,7 @@ endif
# Test programs that are installed and therefore built as part of make, not make check
qpidexectest_SCRIPTS += qpid-cpp-benchmark install_env.sh
-EXTRA_DIST += qpid-cpp-benchmark install_env.sh
+EXTRA_DIST += qpid-cpp-benchmark qpid-cluster-benchmark install_env.sh
qpidexectest_PROGRAMS += receiver
receiver_SOURCES = \
@@ -305,7 +305,7 @@ TESTS_ENVIRONMENT = \
system_tests = qpid-client-test quick_perftest quick_topictest run_header_test quick_txtest \
run_msg_group_tests
TESTS += start_broker $(system_tests) python_tests stop_broker \
- ha_tests.py run_federation_tests run_federation_sys_tests \
+ run_ha_tests run_federation_tests run_federation_sys_tests \
run_acl_tests run_cli_tests replication_test dynamic_log_level_test \
run_queue_flow_limit_tests ipv6_test
@@ -352,7 +352,8 @@ EXTRA_DIST += \
run_queue_flow_limit_tests \
run_msg_group_tests \
ipv6_test \
- ha_tests.py \
+ run_ha_tests \
+ ha_tests.py \
test_env.ps1.in
check_LTLIBRARIES += libdlclose_noop.la
diff --git a/qpid/cpp/src/tests/run_ha_tests b/qpid/cpp/src/tests/run_ha_tests
new file mode 100755
index 0000000000..1a469646c9
--- /dev/null
+++ b/qpid/cpp/src/tests/run_ha_tests
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+
+# Make sure the python tools are available. They will be if we are building in
+# a checkoug, they may not be in a distribution.
+test -d $PYTHON_COMMANDS -a -x $PYTHON_COMMANDS/qpid-ha -a -x $PYTHON_COMMANDS/qpid-config || { echo "Skipping HA tests, qpid-ha or qpid-config not available."; exit 0; }
+
+srcdir=`dirname $0`
+$srcdir/ha_tests.py
+