From 7b92dd140ccee9fc28647df456131152dee177c5 Mon Sep 17 00:00:00 2001 From: Maximilian Albert Date: Thu, 20 Jun 2024 21:21:54 +0100 Subject: [PATCH] chore: linting --- tests/brokers/nats/test_test_client.py | 1 - tests/tools.py | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/brokers/nats/test_test_client.py b/tests/brokers/nats/test_test_client.py index 94a4be5dac..e24cbb577e 100644 --- a/tests/brokers/nats/test_test_client.py +++ b/tests/brokers/nats/test_test_client.py @@ -91,7 +91,6 @@ async def test_inbox_prefix_with_real( assert br._connection._inbox_prefix == b"test" assert "test" in str(br._connection.new_inbox()) - async def test_respect_middleware(self, queue): routes = [] diff --git a/tests/tools.py b/tests/tools.py index 2fe189de6e..48df98a0a1 100644 --- a/tests/tools.py +++ b/tests/tools.py @@ -7,10 +7,12 @@ def spy_decorator(method): mock = MagicMock() if inspect.iscoroutinefunction(method): + async def wrapper(*args, **kwargs): mock(*args, **kwargs) return await method(*args, **kwargs) else: + def wrapper(*args, **kwargs): mock(*args, **kwargs) return method(*args, **kwargs)