diff options
| author | Ted Ross <tross@apache.org> | 2013-09-03 19:47:38 +0000 |
|---|---|---|
| committer | Ted Ross <tross@apache.org> | 2013-09-03 19:47:38 +0000 |
| commit | 581157e0d4514d4bbd963a0ecd97350d816830bf (patch) | |
| tree | 8909eedcea7236d7b39cd80ae2285393d78b6430 | |
| parent | 0d0fb00ffb0db2f8553c8495a694cc1c31ae0315 (diff) | |
| download | qpid-python-581157e0d4514d4bbd963a0ecd97350d816830bf.tar.gz | |
NO-JIRA - Updated for compatibility with changes in Proton 0.5
- Proton Python interface was changed to make timeouts expressed as seconds (floating point).
- Two references to the moved python modules were fixed.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1519811 13f79535-47bb-0310-9956-ffa450edef68
| -rw-r--r-- | qpid/extras/dispatch/src/router_node.c | 2 | ||||
| -rw-r--r-- | qpid/extras/dispatch/tests/router_engine_test.py | 4 | ||||
| -rw-r--r-- | qpid/extras/dispatch/tests/system_tests_one_router.py | 25 |
3 files changed, 15 insertions, 16 deletions
diff --git a/qpid/extras/dispatch/src/router_node.c b/qpid/extras/dispatch/src/router_node.c index cd5343d1e9..c282ed9262 100644 --- a/qpid/extras/dispatch/src/router_node.c +++ b/qpid/extras/dispatch/src/router_node.c @@ -1038,7 +1038,7 @@ static void dx_router_python_setup(dx_router_t *router) PyObject* pClass; PyObject* pArgs; - pName = PyString_FromString("router"); + pName = PyString_FromString("qpid.dispatch.router"); pModule = PyImport_Import(pName); Py_DECREF(pName); if (!pModule) { diff --git a/qpid/extras/dispatch/tests/router_engine_test.py b/qpid/extras/dispatch/tests/router_engine_test.py index 0427879248..605e7568d3 100644 --- a/qpid/extras/dispatch/tests/router_engine_test.py +++ b/qpid/extras/dispatch/tests/router_engine_test.py @@ -18,8 +18,8 @@ # import unittest -from router.router_engine import NeighborEngine, PathEngine, Configuration -from router.data import LinkState, MessageHELLO +from qpid.dispatch.router.router_engine import NeighborEngine, PathEngine, Configuration +from qpid.dispatch.router.data import LinkState, MessageHELLO class Adapter(object): def __init__(self, domain): diff --git a/qpid/extras/dispatch/tests/system_tests_one_router.py b/qpid/extras/dispatch/tests/system_tests_one_router.py index 611f40de8a..23ea78f68a 100644 --- a/qpid/extras/dispatch/tests/system_tests_one_router.py +++ b/qpid/extras/dispatch/tests/system_tests_one_router.py @@ -38,7 +38,7 @@ class RouterTest(unittest.TestCase): self.router.wait() def flush(self, messenger): - while messenger.work(100): + while messenger.work(0.1): pass def subscribe(self, messenger, address): @@ -48,7 +48,7 @@ class RouterTest(unittest.TestCase): def test_0_discard(self): addr = "amqp://0.0.0.0:20000/discard/1" M1 = Messenger() - M1.timeout = 1000 + M1.timeout = 1.0 M1.start() tm = Message() tm.address = addr @@ -58,14 +58,13 @@ class RouterTest(unittest.TestCase): M1.send() M1.stop() - def test_1_pre_settled(self): addr = "amqp://0.0.0.0:20000/pre_settled/1" M1 = Messenger() M2 = Messenger() - M1.timeout = 1000 - M2.timeout = 1000 + M1.timeout = 1.0 + M2.timeout = 1.0 M1.start() M2.start() @@ -96,10 +95,10 @@ class RouterTest(unittest.TestCase): M3 = Messenger() M4 = Messenger() - M1.timeout = 1000 - M2.timeout = 1000 - M3.timeout = 1000 - M4.timeout = 1000 + M1.timeout = 1.0 + M2.timeout = 1.0 + M3.timeout = 1.0 + M4.timeout = 1.0 M1.start() M2.start() @@ -142,8 +141,8 @@ class RouterTest(unittest.TestCase): M1 = Messenger() M2 = Messenger() - M1.timeout = 1000 - M2.timeout = 1000 + M1.timeout = 1.0 + M2.timeout = 1.0 M1.outgoing_window = 5 M2.incoming_window = 5 @@ -205,8 +204,8 @@ class RouterTest(unittest.TestCase): M1 = Messenger() M2 = Messenger() - M1.timeout = 1000 - M2.timeout = 1000 + M1.timeout = 1.0 + M2.timeout = 1.0 M1.outgoing_window = 5 M2.incoming_window = 5 |
