diff options
| author | Alan Conway <aconway@apache.org> | 2015-02-25 17:17:15 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2015-02-25 17:17:15 +0000 |
| commit | e0c7ce135bf77cd98ecdd25b668fbc7140e82b20 (patch) | |
| tree | bf19e49c328a8b486e4831d4c135b5e648290aba /qpid/cpp/src/tests/ha_tests.py | |
| parent | 8219f65028e4ce51962ab373cec8f77880e2e97b (diff) | |
| download | qpid-python-e0c7ce135bf77cd98ecdd25b668fbc7140e82b20.tar.gz | |
QPID-6414: Skip HA tests if qpid-ha or qpid-config tools are not available.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1662275 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/ha_tests.py')
| -rwxr-xr-x | qpid/cpp/src/tests/ha_tests.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/qpid/cpp/src/tests/ha_tests.py b/qpid/cpp/src/tests/ha_tests.py index a43b939ee3..1d475ebfe7 100755 --- a/qpid/cpp/src/tests/ha_tests.py +++ b/qpid/cpp/src/tests/ha_tests.py @@ -1631,12 +1631,14 @@ class TransactionTests(HaBrokerTest): "*.tx.*"]).assert_exit_ok() if __name__ == "__main__": - outdir = "ha_tests.tmp" - shutil.rmtree(outdir, True) - qpid_ha = os.getenv("QPID_HA_EXEC") - if qpid_ha and os.path.exists(qpid_ha): + qpid_ha_exec = os.getenv("QPID_HA_EXEC") + if qpid_ha_exec and os.path.isfile(qpid_ha_exec): + outdir = "ha_tests.tmp" + shutil.rmtree(outdir, True) os.execvp("qpid-python-test", - ["qpid-python-test", "-m", "ha_tests", "-DOUTDIR=%s"%outdir] + ["qpid-python-test", "-m", "ha_tests", "-DOUTDIR=%s"%outdir] + sys.argv[1:]) else: - print "Skipping ha_tests, %s not available"%(qpid_ha) + print "Skipping ha_tests, qpid-ha not available" + + |
