From 03cd19556c261f43a8d95bd7d803c59bd488aeef Mon Sep 17 00:00:00 2001 From: Gordon Sim Date: Fri, 21 Sep 2007 10:39:36 +0000 Subject: Use octet each for class and method id (changed c++ and python) Modified indexes in xml for message.empty, message.offset and the c++ cluster class Fixed encoding for rfc1982-long-set in c++ and python (its a size not a count that is prepended) Fixed minor typo in configuration option help string Use session.open/close in python tests, handle session.closed Commented out the response tag in session.close due to pythons ambiguity as to whether session.closed is a response or not Disabled broker.test_closed_channel (due to above issue); broker behaves as expected but test fails; test_invalid_channel is safe enough for now. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@578053 13f79535-47bb-0310-9956-ffa450edef68 --- python/qpid/testlib.py | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'python/qpid/testlib.py') diff --git a/python/qpid/testlib.py b/python/qpid/testlib.py index ce1ba462a0..c4f55be18a 100644 --- a/python/qpid/testlib.py +++ b/python/qpid/testlib.py @@ -208,8 +208,8 @@ class TestBase(unittest.TestCase): self.exchanges = [] self.client = self.connect() self.channel = self.client.channel(1) - version = (self.client.spec.major, self.client.spec.minor) - if version == (8, 0) or "transitional" in self.client.spec.file: + self.version = (self.client.spec.major, self.client.spec.minor) + if self.version == (8, 0): self.channel.channel_open() else: self.channel.session_open() @@ -313,9 +313,14 @@ class TestBase(unittest.TestCase): self.assertPublishGet(self.consume(queue), exchange, routing_key, properties) def assertChannelException(self, expectedCode, message): - if not isinstance(message, Message): self.fail("expected channel_close method, got %s" % (message)) - self.assertEqual("channel", message.method.klass.name) - self.assertEqual("close", message.method.name) + if self.version == (8, 0): #or "transitional" in self.client.spec.file: + if not isinstance(message, Message): self.fail("expected channel_close method, got %s" % (message)) + self.assertEqual("channel", message.method.klass.name) + self.assertEqual("close", message.method.name) + else: + if not isinstance(message, Message): self.fail("expected session_closed method, got %s" % (message)) + self.assertEqual("session", message.method.klass.name) + self.assertEqual("closed", message.method.name) self.assertEqual(expectedCode, message.reply_code) -- cgit v1.2.1