diff options
Diffstat (limited to 'cpp/src/tests/federated_cluster_test')
-rwxr-xr-x | cpp/src/tests/federated_cluster_test | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/cpp/src/tests/federated_cluster_test b/cpp/src/tests/federated_cluster_test index b32455259e..f42b7501b8 100755 --- a/cpp/src/tests/federated_cluster_test +++ b/cpp/src/tests/federated_cluster_test @@ -8,9 +8,9 @@ # 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 @@ -35,7 +35,7 @@ stop_brokers() { if [[ $BROKER_A ]] ; then ../qpidd --no-module-dir -q --port $BROKER_A unset BROKER_A - fi + fi if [[ $NODE_1 ]] ; then ../qpidd --no-module-dir -q --port $NODE_1 unset NODE_1 @@ -63,20 +63,20 @@ start_brokers() { setup() { #create exchange on both cluster and single broker - $PYTHON_COMMANDS/qpid-config -a "localhost:$BROKER_A" add exchange direct test-exchange - $PYTHON_COMMANDS/qpid-config -a "localhost:$NODE_1" add exchange direct test-exchange + $PYTHON_COMMANDS/qpid-config -b "localhost:$BROKER_A" add exchange direct test-exchange + $PYTHON_COMMANDS/qpid-config -b "localhost:$NODE_1" add exchange direct test-exchange #create dynamic routes for test exchange $PYTHON_COMMANDS/qpid-route dynamic add "localhost:$NODE_2" "localhost:$BROKER_A" test-exchange $PYTHON_COMMANDS/qpid-route dynamic add "localhost:$BROKER_A" "localhost:$NODE_2" test-exchange #create test queue on cluster and bind it to the test exchange - $PYTHON_COMMANDS/qpid-config -a "localhost:$NODE_1" add queue test-queue - $PYTHON_COMMANDS/qpid-config -a "localhost:$NODE_1" bind test-exchange test-queue to-cluster + $PYTHON_COMMANDS/qpid-config -b "localhost:$NODE_1" add queue test-queue + $PYTHON_COMMANDS/qpid-config -b "localhost:$NODE_1" bind test-exchange test-queue to-cluster #create test queue on single broker and bind it to the test exchange - $PYTHON_COMMANDS/qpid-config -a "localhost:$BROKER_A" add queue test-queue - $PYTHON_COMMANDS/qpid-config -a "localhost:$BROKER_A" bind test-exchange test-queue from-cluster + $PYTHON_COMMANDS/qpid-config -b "localhost:$BROKER_A" add queue test-queue + $PYTHON_COMMANDS/qpid-config -b "localhost:$BROKER_A" bind test-exchange test-queue from-cluster } run_test_pull_to_cluster_two_consumers() { @@ -92,7 +92,7 @@ run_test_pull_to_cluster_two_consumers() { wait sort -g -k 2 fed1.out.tmp fed2.out.tmp > fed.out.tmp diff fed.in.tmp fed.out.tmp || fail "federated link to cluster failed: expectations not met!" - + rm -f fed*.tmp #cleanup } @@ -106,7 +106,7 @@ run_test_pull_to_cluster() { #verify all messages are received diff fed.in.tmp fed.out.tmp || fail "federated link to cluster failed: expectations not met!" - + rm -f fed*.tmp #cleanup } @@ -121,22 +121,23 @@ run_test_pull_from_cluster() { #verify all messages are received wait diff fed.in.tmp fed.out.tmp || fail "federated link from cluster failed: expectations not met!" - + rm -f fed*.tmp #cleanup } if test -d ${PYTHON_DIR}; then - . $srcdir/ais_check + . cpg_check.sh + cpg_enabled || exit 0 rm -f fed*.tmp #cleanup any files left from previous run start_brokers echo "brokers started" setup echo "setup completed" - run_test_pull_to_cluster_two_consumers + run_test_pull_to_cluster_two_consumers echo "federated link to cluster verified" - run_test_pull_from_cluster + run_test_pull_from_cluster echo "federated link from cluster verified" if [[ $TEST_NODE_FAILURE ]] ; then #kill first cluster node and retest @@ -146,7 +147,7 @@ if test -d ${PYTHON_DIR}; then echo "retesting..." run_test_pull_to_cluster echo "federated link to cluster verified" - run_test_pull_from_cluster - echo "federated link from cluster verified" + run_test_pull_from_cluster + echo "federated link from cluster verified" fi fi |