diff options
Diffstat (limited to 'python/qpid/tests/messaging.py')
-rw-r--r-- | python/qpid/tests/messaging.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/python/qpid/tests/messaging.py b/python/qpid/tests/messaging.py index 15cc776f44..8a142d6c96 100644 --- a/python/qpid/tests/messaging.py +++ b/python/qpid/tests/messaging.py @@ -22,7 +22,7 @@ import time from qpid.tests import Test -from qpid.messaging import Connection, Disconnected, Empty, Message, UNLIMITED, uuid4 +from qpid.messaging import Connection, ConnectError, Disconnected, Empty, Message, UNLIMITED, uuid4 from Queue import Queue, Empty as QueueEmpty class Base(Test): @@ -99,6 +99,13 @@ class SetupTests(Base): self.conn.connect() self.ping(self.conn.session()) + def testConnectError(self): + try: + self.conn = Connection.open("localhost", 0) + assert False, "connect succeeded" + except ConnectError: + pass + class ConnectionTests(Base): def setup_connection(self): |