qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From g...@apache.org
Subject svn commit: r1074698 - in /qpid/trunk/qpid/cpp/src/tests: cli_tests.py run_cli_tests
Date Fri, 25 Feb 2011 20:54:02 GMT
Author: gsim
Date: Fri Feb 25 20:54:02 2011
New Revision: 1074698

URL: http://svn.apache.org/viewvc?rev=1074698&view=rev
Log:
QPID-3087: add extra test for qpid-config and handling string values in arguments

Modified:
    qpid/trunk/qpid/cpp/src/tests/cli_tests.py
    qpid/trunk/qpid/cpp/src/tests/run_cli_tests

Modified: qpid/trunk/qpid/cpp/src/tests/cli_tests.py
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/cli_tests.py?rev=1074698&r1=1074697&r2=1074698&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/cli_tests.py (original)
+++ qpid/trunk/qpid/cpp/src/tests/cli_tests.py Fri Feb 25 20:54:02 2011
@@ -365,6 +365,26 @@ class CliTests(TestBase010):
                 self.assertEqual(queue._altExchange_.name, altName)
         self.assertEqual(found, True)
 
+    def test_qpid_config_list_queues_arguments(self):
+        """
+        Test to verify that when the type of a policy limit is
+        actually a string (though still a valid value), it does not
+        upset qpid-config
+        """
+        self.startQmf();
+        qmf = self.qmf
+
+        names = ["queue_capacity%s" % (i) for i in range(1, 6)]
+        for name in names:
+            self.session.queue_declare(queue=name, exclusive=True,
+                                       arguments={'qpid.max_count' : str(i), 'qpid.max_size':
'100'})
+
+        output = os.popen(self.qpid_config_command(" queues")).readlines()
+        queues = [line.split()[0] for line in output[2:len(output)]] #ignore first two lines
(header)
+
+        for name in names:
+            assert name in queues, "%s not in %s" % (name, queues)
+
     def test_qpid_route(self):
         self.startQmf();
         qmf = self.qmf

Modified: qpid/trunk/qpid/cpp/src/tests/run_cli_tests
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_cli_tests?rev=1074698&r1=1074697&r2=1074698&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/run_cli_tests (original)
+++ qpid/trunk/qpid/cpp/src/tests/run_cli_tests Fri Feb 25 20:54:02 2011
@@ -70,7 +70,8 @@ stop_brokers() {
 if test -d ${PYTHON_DIR} ;  then
     start_brokers
     echo "Running CLI tests using brokers on ports $LOCAL_PORT $REMOTE_PORT"
-    $QPID_PYTHON_TEST -m cli_tests -b localhost:$LOCAL_PORT -Dremote-port=$REMOTE_PORT -Dcli-dir=$CLI_DIR
$targs $@
+    PYTHON_TESTS=${PYTHON_TESTS:-$*}
+    $QPID_PYTHON_TEST -m cli_tests -b localhost:$LOCAL_PORT -Dremote-port=$REMOTE_PORT -Dcli-dir=$CLI_DIR
$targs $PYTHON_TESTS $@
     RETCODE=$?
     stop_brokers
     if test x$RETCODE != x0; then 



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message