Add production Docker Compose setup with Nginx and SSL; enhance test fixtures and environment variables for monitoring, logging, and schema caching; and clean up unused imports.
This commit is contained in:
parent
bf5d1b890a
commit
283d7deee4
6 changed files with 109 additions and 58 deletions
|
|
@ -1,10 +1,11 @@
|
|||
"""Shared test fixtures."""
|
||||
|
||||
from unittest.mock import AsyncMock, MagicMock
|
||||
from unittest.mock import AsyncMock, MagicMock, patch
|
||||
|
||||
import pytest
|
||||
|
||||
from geoguessr_mcp.api.dynamic_response import DynamicResponse
|
||||
from geoguessr_mcp.auth import SessionManager
|
||||
from geoguessr_mcp.models import RoundGuess, Game
|
||||
from geoguessr_mcp.services import AnalysisService, GameService, ProfileService
|
||||
|
||||
|
|
@ -32,6 +33,21 @@ def mock_session():
|
|||
return mock_client
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def session_manager():
|
||||
return SessionManager()
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def mock_httpx_client():
|
||||
with patch("httpx.AsyncClient") as mock_client_class:
|
||||
mock_client = AsyncMock()
|
||||
mock_client.__aenter__.return_value = mock_client
|
||||
mock_client.__aexit__.return_value = None
|
||||
mock_client_class.return_value = mock_client
|
||||
yield mock_client
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def mock_game_service():
|
||||
"""Create a mock GameService."""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue