summaryrefslogtreecommitdiff
path: root/test/test_consumer.py
diff options
context:
space:
mode:
authorBruno ReniƩ <brutasse@gmail.com>2014-08-28 14:40:01 +0200
committerMark Roberts <wizzat@fb.com>2014-09-03 09:55:44 -0700
commit83af5102e995e854a1980b90f1400afdd098da37 (patch)
tree403e6dabbe62ac4f5bb6b2a76a5eed0f183d86b3 /test/test_consumer.py
parenteddd1436c226545237aa057c35719950702466ed (diff)
downloadkafka-python-83af5102e995e854a1980b90f1400afdd098da37.tar.gz
Use base unittest or unittest2 depending on python version
Diffstat (limited to 'test/test_consumer.py')
-rw-r--r--test/test_consumer.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/test_consumer.py b/test/test_consumer.py
index 778d76a..7d7fc46 100644
--- a/test/test_consumer.py
+++ b/test/test_consumer.py
@@ -1,7 +1,7 @@
import os
import random
import struct
-import unittest2
+from . import unittest
from mock import MagicMock, patch
@@ -16,7 +16,7 @@ from kafka.protocol import (
create_message, KafkaProtocol
)
-class TestKafkaConsumer(unittest2.TestCase):
+class TestKafkaConsumer(unittest.TestCase):
def test_non_integer_partitions(self):
with self.assertRaises(AssertionError):
consumer = SimpleConsumer(MagicMock(), 'group', 'topic', partitions = [ '0' ])