diff options
| author | Gordon Sim <gsim@apache.org> | 2008-04-09 19:52:44 +0000 |
|---|---|---|
| committer | Gordon Sim <gsim@apache.org> | 2008-04-09 19:52:44 +0000 |
| commit | 6cf06312f5f9d686a0af76f7c1c08732a7ae27cb (patch) | |
| tree | d415498924b234d73645a9ae74f486085fe63f15 /cpp/src/tests/run_federation_tests | |
| parent | 363ed6d7e6a0986c49a9ae5d43954dfec08e7e8c (diff) | |
| download | qpid-python-6cf06312f5f9d686a0af76f7c1c08732a7ae27cb.tar.gz | |
Fixes and automated tests for federation function.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@646505 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/tests/run_federation_tests')
| -rwxr-xr-x | cpp/src/tests/run_federation_tests | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/cpp/src/tests/run_federation_tests b/cpp/src/tests/run_federation_tests new file mode 100755 index 0000000000..63f0baa1ae --- /dev/null +++ b/cpp/src/tests/run_federation_tests @@ -0,0 +1,24 @@ +#!/bin/sh +# Run the federation tests. + +trap stop_brokers EXIT + +start_brokers() { + ../qpidd --daemon --port 0 --no-data-dir > qpidd.port + LOCAL_PORT=`cat qpidd.port` + ../qpidd --daemon --port 0 --no-data-dir > qpidd.port + REMOTE_PORT=`cat qpidd.port` +} + +stop_brokers() { + ../qpidd -q --port $LOCAL_PORT + ../qpidd -q --port $REMOTE_PORT +} + +if test -d ../../../python ; then + start_brokers + echo "Running federation tests using brokers on ports $LOCAL_PORT $REMOTE_PORT" + export PYTHONPATH=../../../python + ./federation.py -v -s ../../../specs/amqp.0-10-preview.xml -b localhost:$LOCAL_PORT --remote-port $REMOTE_PORT || { echo "FAIL federation tests"; exit 1; } +fi + |
