fix: use AsyncMock for mock_channel in test setup

Co-authored-by: aider (openrouter/openai/o3-mini-high) <aider@aider.chat>
This commit is contained in:
Stanislav Hejny
2025-07-18 09:25:34 +01:00
parent f2cc138540
commit a6ca319e92
@@ -40,8 +40,8 @@ class TestUserManagementServiceClient(unittest.IsolatedAsyncioTestCase):
mock_connection = MagicMock()
mock_connect.return_value = mock_connection
# Mock channel
mock_channel = MagicMock()
# Mock channel - use AsyncMock for async methods
mock_channel = AsyncMock()
mock_connection.channel.return_value = mock_channel
mock_channel.set_qos = AsyncMock()