diff options
author | Bruno ReniƩ <brutasse@gmail.com> | 2014-08-28 20:50:20 +0200 |
---|---|---|
committer | Mark Roberts <wizzat@fb.com> | 2014-09-03 09:55:44 -0700 |
commit | cf0b7f0530e765f2cf710bd35daf53bb4ea205d2 (patch) | |
tree | f38669f145112a7f301691f311b3c8aca51d1f59 /test/testutil.py | |
parent | 83af5102e995e854a1980b90f1400afdd098da37 (diff) | |
download | kafka-python-cf0b7f0530e765f2cf710bd35daf53bb4ea205d2.tar.gz |
Make all unit tests pass on py3.3/3.4
Diffstat (limited to 'test/testutil.py')
-rw-r--r-- | test/testutil.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/testutil.py b/test/testutil.py index e7dcda6..8584509 100644 --- a/test/testutil.py +++ b/test/testutil.py @@ -7,6 +7,8 @@ import string import time import uuid +from six.moves import xrange + from . import unittest from kafka.common import OffsetRequest @@ -21,8 +23,8 @@ __all__ = [ ] def random_string(l): - s = "".join(random.choice(string.letters) for i in xrange(l)) - return s + s = "".join(random.choice(string.ascii_letters) for i in xrange(l)) + return s.encode('utf-8') def kafka_versions(*versions): def kafka_versions(func): |