diff options
| author | Justin Ross <jross@apache.org> | 2013-04-23 21:40:49 +0000 |
|---|---|---|
| committer | Justin Ross <jross@apache.org> | 2013-04-23 21:40:49 +0000 |
| commit | 9cdafd3578ef44b0988506aba96d4c2af48f86a8 (patch) | |
| tree | 93773f4c644dd523b5961d32f64471e718c64a6e /python/qpid/tests | |
| parent | 47c0100cc929caa7b4c1e6d3a70a9472bfeb05ac (diff) | |
| download | qpid-python-9cdafd3578ef44b0988506aba96d4c2af48f86a8.tar.gz | |
QPID-2453: Allow the session to keep operating after content codec errors; a patch from Ernie Allen
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1471158 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'python/qpid/tests')
| -rw-r--r-- | python/qpid/tests/messaging/message.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/python/qpid/tests/messaging/message.py b/python/qpid/tests/messaging/message.py index 297374b82b..7328165db7 100644 --- a/python/qpid/tests/messaging/message.py +++ b/python/qpid/tests/messaging/message.py @@ -153,3 +153,16 @@ class MessageEchoTests(Base): f = echo.content["false"] assert isinstance(t, bool), t assert isinstance(f, bool), f + + def testExceptionRaisedMismatchedContentType(self): + msg = Message(content_type="amqp/map", content="asdf") + try: + self.snd.send(msg) + self.rcv.fetch(0) + assert False, "Exception not raised on mismatched content/content_type" + except Exception, e: + pass + + def testRecoverAfterException(self): + self.testExceptionRaisedMismatchedContentType() + self.testTextPlain() |
