qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Godfrey" <rob.j.godf...@gmail.com>
Subject Python Test: test.queue.QueueTests.test_purge and Connection Closing
Date Wed, 17 Jan 2007 12:14:59 GMT

I've been working on the Java broker to get it compliant with the python
tests.  On my working copy I have it working with all tests except those
that require wildcard Topic matching (which I believe Martin will be
implementing shortly).  However, there is one test where I am unsure whether
there is a bug in the test, or whether my understanding of Python/AMQP is

in test.queue.QueueTests.test_purge we have the following code:

            #queue not specified and none previously declared for channel:
            self.fail("Expected failure when purging unspecified queue")
        except Closed, e:
            self.assertConnectionException(530, e.args[0])

        channel = self.client.channel(4)

That it is asserts that there is a connection exception, of error code 530 -
but (I believe) it then attempts to open a channel on the same connection.
This test was failing for me (after I implemented Queue.purge) because the
channel_open fails.

I could make the test pass by having the broker return a connection
exception and not close the connection... but my understanding was that if
you get a connection exception, then the connection will be closed.

Am I correct in my understanding, and is the python test therefore broken?



  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message