qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jr...@apache.org
Subject svn commit: r1741266 - in /qpid/trunk/qpid/cpp/src/tests: run_interop_tests run_python_tests
Date Wed, 27 Apr 2016 13:48:16 GMT
Author: jross
Date: Wed Apr 27 13:48:16 2016
New Revision: 1741266

URL: http://svn.apache.org/viewvc?rev=1741266&view=rev
Log:
QPID-7207: Skip some tests when the swigged python client is not available

Modified:
    qpid/trunk/qpid/cpp/src/tests/run_interop_tests
    qpid/trunk/qpid/cpp/src/tests/run_python_tests

Modified: qpid/trunk/qpid/cpp/src/tests/run_interop_tests
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_interop_tests?rev=1741266&r1=1741265&r2=1741266&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/run_interop_tests (original)
+++ qpid/trunk/qpid/cpp/src/tests/run_interop_tests Wed Apr 27 13:48:16 2016
@@ -21,10 +21,15 @@
 
 from common import *
 
-port = start_broker("broker", "--load-module {0}".format(AMQP_LIB))
+python_swig_module = join(BUILD_DIR, "bindings", "qpid", "python", "qpid_messaging.py")
 
-ENV["QPID_INTEROP_URL"] = "localhost:{0}".format(port)
+if exists(python_swig_module):
+    port = start_broker("broker", "--load-module {0}".format(AMQP_LIB))
 
-call("qpid-python-test -m interop_tests -DOUTDIR={0}", WORK_DIR)
+    ENV["QPID_INTEROP_URL"] = "localhost:{0}".format(port)
+
+    call("qpid-python-test -m interop_tests -DOUTDIR={0}", WORK_DIR)
+else:
+    warn("Skipping tests: 1.0 messaging client not found")
 
 check_results()

Modified: qpid/trunk/qpid/cpp/src/tests/run_python_tests
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_python_tests?rev=1741266&r1=1741265&r2=1741266&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/run_python_tests (original)
+++ qpid/trunk/qpid/cpp/src/tests/run_python_tests Wed Apr 27 13:48:16 2016
@@ -37,26 +37,31 @@ run_broker_tests(port, "-m qpid_tests.br
 
 # Swigged python tests
 
-failing_tests = join(BUILD_DIR, "src", "tests", "failing-amqp0-10-python-tests")
+python_swig_module = join(BUILD_DIR, "bindings", "qpid", "python", "qpid_messaging.py")
 
-ENV["QPID_USE_SWIG_CLIENT"] = "1"
+if exists(python_swig_module):
+    failing_tests = join(BUILD_DIR, "src", "tests", "failing-amqp0-10-python-tests")
 
-run_broker_tests(port, 
-                 "-m qpid.tests.messaging.message",
-                 "-m qpid_tests.broker_0_10.priority",
-                 "-m qpid_tests.broker_0_10.lvq",
-                 "-m qpid_tests.broker_0_10.new_api",
-                 "-I {0}".format(failing_tests))
-
-if AMQP_LIB is not None:
-    failing_tests = join(BUILD_DIR, "src", "tests", "failing-amqp1.0-python-tests")
-
-    run_broker_tests(port,
-                     "--define=\"protocol_version=amqp1.0\"",
-                     "--define=\"policy_file={0}\"".format(acl_file),
-                     "-m qpid_tests.broker_1_0",
+    ENV["QPID_USE_SWIG_CLIENT"] = "1"
+
+    run_broker_tests(port, 
+                     "-m qpid.tests.messaging.message",
+                     "-m qpid_tests.broker_0_10.priority",
+                     "-m qpid_tests.broker_0_10.lvq",
                      "-m qpid_tests.broker_0_10.new_api",
-                     "-m assertions -m reject_release -m misc -m policies -m acl_1",
                      "-I {0}".format(failing_tests))
 
+    if AMQP_LIB is not None:
+        failing_tests = join(BUILD_DIR, "src", "tests", "failing-amqp1.0-python-tests")
+
+        run_broker_tests(port,
+                         "--define=\"protocol_version=amqp1.0\"",
+                         "--define=\"policy_file={0}\"".format(acl_file),
+                         "-m qpid_tests.broker_1_0",
+                         "-m qpid_tests.broker_0_10.new_api",
+                         "-m assertions -m reject_release -m misc -m policies -m acl_1",
+                         "-I {0}".format(failing_tests))
+else:
+    warn("Skipping tests for swigged python client: swigged module not found")
+    
 check_results()



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


Mime
View raw message