From cf0b7f0530e765f2cf710bd35daf53bb4ea205d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bruno=20Reni=C3=A9?= Date: Thu, 28 Aug 2014 20:50:20 +0200 Subject: Make all unit tests pass on py3.3/3.4 --- test/testutil.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'test/testutil.py') 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): -- cgit v1.2.1