mirror of https://github.com/celery/kombu.git
Tests passing on Py3
This commit is contained in:
parent
f80e0c349f
commit
49de25a175
|
@ -1,5 +1,6 @@
|
|||
from __future__ import absolute_import
|
||||
|
||||
import sys
|
||||
import warnings
|
||||
|
||||
from kombu import Connection
|
||||
|
@ -10,6 +11,9 @@ from kombu.compression import compress
|
|||
|
||||
from kombu.tests.case import Case, Mock, patch, redirect_stdouts
|
||||
|
||||
PY3 = sys.version_info[0] == 3
|
||||
PRINT_FQDN = 'builtins.print' if PY3 else '__builtin__.print'
|
||||
|
||||
|
||||
def client(**kwargs):
|
||||
return Connection(transport='kombu.transport.virtual:Transport', **kwargs)
|
||||
|
@ -393,7 +397,7 @@ class test_Channel(Case):
|
|||
self.assertFalse(q._delivered)
|
||||
|
||||
@patch('kombu.transport.virtual.emergency_dump_state')
|
||||
@patch('__builtin__.print')
|
||||
@patch(PRINT_FQDN)
|
||||
def test_restore_unacked_once_when_unrestored(self, print_,
|
||||
emergency_dump_state):
|
||||
q = self.channel.qos
|
||||
|
|
Loading…
Reference in New Issue