Merge "Pop _unique_id when checking for duplicates"
This commit is contained in:
commit
2f1b87d2f0
@ -323,7 +323,7 @@ class _MsgIdCache(object):
|
||||
before ack is returned. This method prevents doing it.
|
||||
"""
|
||||
if UNIQUE_ID in message_data:
|
||||
msg_id = message_data[UNIQUE_ID]
|
||||
msg_id = message_data.pop(UNIQUE_ID)
|
||||
if msg_id not in self.prev_msgids:
|
||||
self.prev_msgids.append(msg_id)
|
||||
else:
|
||||
|
@ -52,7 +52,4 @@ class TestRabbitDriver(test_utils.BaseTestCase):
|
||||
received = listener.poll()
|
||||
self.assertTrue(received is not None)
|
||||
self.assertEquals(received.ctxt, {})
|
||||
|
||||
# FIXME(markmc): this should be done by the driver
|
||||
received.message.pop('_unique_id')
|
||||
self.assertEquals(received.message, {'foo': 'bar'})
|
||||
|
Loading…
x
Reference in New Issue
Block a user