diff --git a/tests/test_consumer.py b/tests/test_consumer.py index 8eabd4a1..844d16f0 100644 --- a/tests/test_consumer.py +++ b/tests/test_consumer.py @@ -450,19 +450,18 @@ def test_check_extended_message_record(self): def test_equal_consumption(self): # A strange use case of kafka-python, that can be reproduced in # aiokafka https://github.com/dpkp/kafka-python/issues/675 - yield from self.send_messages(0, list(range(1000))) - yield from self.send_messages(1, list(range(1000))) + yield from self.send_messages(0, list(range(200))) + yield from self.send_messages(1, list(range(200))) partition_consumption = [0, 0] for x in range(10): consumer = yield from self.consumer_factory( max_partition_fetch_bytes=10000) - for x in range(50): + for x in range(10): msg = yield from consumer.getone() partition_consumption[msg.partition] += 1 yield from consumer.stop() - print(partition_consumption) diff = abs(partition_consumption[0] - partition_consumption[1]) # We are good as long as it's not 100%, as we do rely on randomness of # a shuffle in code. Ideally it should be 50/50 (0 diff) thou