File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 11import os
22from typing import AsyncGenerator
3+ from uuid import uuid4
34
45import pytest
56from aiokafka import AIOKafkaConsumer , AIOKafkaProducer
@@ -35,7 +36,7 @@ def base_topic_name() -> str:
3536
3637 :returns: topic name.
3738 """
38- return "taskiq_topic"
39+ return uuid4 (). hex
3940
4041
4142@pytest .fixture ()
@@ -134,8 +135,8 @@ async def broker(
134135 bootstrap_servers = kafka_url ,
135136 aiokafka_producer = test_kafka_producer ,
136137 aiokafka_consumer = test_kafka_consumer ,
137- delete_topic_on_shutdown = True ,
138138 kafka_topic = base_topic ,
139+ delete_topic_on_shutdown = True ,
139140 )
140141 broker .is_worker_process = True
141142
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ async def test_startup(
7373 str
7474 ] = broker_without_arguments ._kafka_admin_client .list_topics () # noqa: WPS437
7575
76- assert base_topic_name in all_kafka_topics
76+ assert broker_without_arguments . _kafka_topic . name in all_kafka_topics
7777
7878
7979@pytest .mark .anyio
You can’t perform that action at this time.
0 commit comments