diff options
author | Gordon Sim <gsim@apache.org> | 2008-06-02 09:33:58 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2008-06-02 09:33:58 +0000 |
commit | 3cadb072adbd7ea1daa38e61ad17995c4d661dfc (patch) | |
tree | e71de80ff4f8cb08a17ea7d433c7b009850b3a4f | |
parent | 9c4205052e0310bac49708e37194a398745a824f (diff) | |
download | qpid-python-3cadb072adbd7ea1daa38e61ad17995c4d661dfc.tar.gz |
Minor updates to tests:
* sync on commit in transactional topic test
* disable loading of modules from automated test to preserve isolation
* update federated topic test script in line with command line option changes
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@662373 13f79535-47bb-0310-9956-ffa450edef68
-rwxr-xr-x | cpp/src/tests/federated_topic_test | 18 | ||||
-rwxr-xr-x | cpp/src/tests/run_federation_tests | 4 | ||||
-rwxr-xr-x | cpp/src/tests/start_broker | 2 | ||||
-rw-r--r-- | cpp/src/tests/topic_listener.cpp | 2 | ||||
-rw-r--r-- | cpp/src/tests/topic_publisher.cpp | 4 |
5 files changed, 15 insertions, 15 deletions
diff --git a/cpp/src/tests/federated_topic_test b/cpp/src/tests/federated_topic_test index 9e769b5de5..dbb4a2a133 100755 --- a/cpp/src/tests/federated_topic_test +++ b/cpp/src/tests/federated_topic_test @@ -27,11 +27,11 @@ PYTHON_DIR=${MY_DIR}/../../../python trap stop_brokers EXIT start_brokers() { - ${MY_DIR}/../qpidd --daemon --port 0 --no-data-dir --auth no > qpidd.port + ${MY_DIR}/../qpidd --daemon --port 0 --no-module-dir --no-data-dir --auth no > qpidd.port PORT_A=`cat qpidd.port` - ${MY_DIR}/../qpidd --daemon --port 0 --no-data-dir --auth no > qpidd.port + ${MY_DIR}/../qpidd --daemon --port 0 --no-module-dir --no-data-dir --auth no > qpidd.port PORT_B=`cat qpidd.port` - ${MY_DIR}/../qpidd --daemon --port 0 --no-data-dir --auth no > qpidd.port + ${MY_DIR}/../qpidd --daemon --port 0 --no-module-dir --no-data-dir --auth no > qpidd.port PORT_C=`cat qpidd.port` } @@ -64,16 +64,16 @@ setup_routes() { BROKER_C="localhost:$PORT_C" export PYTHONPATH=$PYTHON_DIR:$PYTHONPATH echo "Establishing routes for topic..." - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_B $BROKER_A amq.topic topic_control B B - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_C $BROKER_B amq.topic topic_control C C + $PYTHON_DIR/commands/qpid-route add $BROKER_B $BROKER_A amq.topic topic_control B B + $PYTHON_DIR/commands/qpid-route add $BROKER_C $BROKER_B amq.topic topic_control C C echo "linked A->B->C" - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_B $BROKER_C amq.topic topic_control B B - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_A $BROKER_B amq.topic topic_control A A + $PYTHON_DIR/commands/qpid-route add $BROKER_B $BROKER_C amq.topic topic_control B B + $PYTHON_DIR/commands/qpid-route add $BROKER_A $BROKER_B amq.topic topic_control A A echo "linked C->B->A" echo "Establishing routes for response queue..." - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_B $BROKER_C amq.direct response B B - $PYTHON_DIR/commands/qpid-route -s ~/qpid/trunk/qpid/specs/amqp.0-10.xml add $BROKER_A $BROKER_B amq.direct response A A + $PYTHON_DIR/commands/qpid-route add $BROKER_B $BROKER_C amq.direct response B B + $PYTHON_DIR/commands/qpid-route add $BROKER_A $BROKER_B amq.direct response A A echo "linked C->B->A" } diff --git a/cpp/src/tests/run_federation_tests b/cpp/src/tests/run_federation_tests index 1e2352568f..3a85f15c46 100755 --- a/cpp/src/tests/run_federation_tests +++ b/cpp/src/tests/run_federation_tests @@ -6,9 +6,9 @@ PYTHON_DIR=${MY_DIR}/../../../python trap stop_brokers EXIT start_brokers() { - ../qpidd --daemon --port 0 --no-data-dir --auth no > qpidd.port + ../qpidd --daemon --port 0 --no-data-dir --no-module-dir --auth no > qpidd.port LOCAL_PORT=`cat qpidd.port` - ../qpidd --daemon --port 0 --no-data-dir --auth no > qpidd.port + ../qpidd --daemon --port 0 --no-data-dir --no-module-dir --auth no > qpidd.port REMOTE_PORT=`cat qpidd.port` } diff --git a/cpp/src/tests/start_broker b/cpp/src/tests/start_broker index 7d5cb7d73d..be5a1b00e4 100755 --- a/cpp/src/tests/start_broker +++ b/cpp/src/tests/start_broker @@ -1,4 +1,4 @@ #!/bin/sh rm -f qpidd.vglog qpidd.log test -n "$VALGRIND" && VALGRIND="$VALGRIND --log-file-exactly=qpidd.vglog --" -exec libtool --mode=execute $VALGRIND ../qpidd --auth no --daemon --port 0 --log-output qpidd.log "$@" > qpidd.port +exec libtool --mode=execute $VALGRIND ../qpidd --auth no --no-module-dir --daemon --port 0 --log-output qpidd.log "$@" > qpidd.port diff --git a/cpp/src/tests/topic_listener.cpp b/cpp/src/tests/topic_listener.cpp index 6daf928401..89419c9c7a 100644 --- a/cpp/src/tests/topic_listener.cpp +++ b/cpp/src/tests/topic_listener.cpp @@ -184,7 +184,7 @@ void Listener::report(){ msg.getHeaders().setString("TYPE", "REPORT"); session.messageTransfer(arg::destination="amq.direct", arg::content=msg, arg::acceptMode=1); if(transactional){ - session.txCommit(); + sync(session).txCommit(); } } diff --git a/cpp/src/tests/topic_publisher.cpp b/cpp/src/tests/topic_publisher.cpp index c8f0d543ec..0f3406a1fe 100644 --- a/cpp/src/tests/topic_publisher.cpp +++ b/cpp/src/tests/topic_publisher.cpp @@ -171,7 +171,7 @@ int64_t Publisher::publish(int msgs, int listeners, int size){ reportRequest.getHeaders().setString("TYPE", "REPORT_REQUEST"); session.messageTransfer(arg::content=reportRequest, arg::destination="amq.topic", arg::acceptMode=1); if(transactional){ - session.txCommit(); + sync(session).txCommit(); } //wait for a response from each listener (TODO, could log these) for (int i = 0; i < listeners; i++) { @@ -179,7 +179,7 @@ int64_t Publisher::publish(int msgs, int listeners, int size){ } if(transactional){ - session.txCommit(); + sync(session).txCommit(); } AbsTime finish = now(); |