- Remove all emoji characters from output strings for better compatibility - Update all tests to match non-emoji output - Apply black formatting to all Python files - Ensure all tests pass and linting succeeds - Remove htmlcov directory (already in .gitignore) This change improves cross-platform compatibility and ensures consistent code formatting across the project. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
29 lines
786 B
Python
29 lines
786 B
Python
"""
|
|
Pytest configuration for Gemini MCP Server tests
|
|
"""
|
|
|
|
import sys
|
|
import os
|
|
from pathlib import Path
|
|
|
|
# Ensure the parent directory is in the Python path for imports
|
|
parent_dir = Path(__file__).resolve().parent.parent
|
|
if str(parent_dir) not in sys.path:
|
|
sys.path.insert(0, str(parent_dir))
|
|
|
|
# Set dummy API key for tests if not already set
|
|
if "GEMINI_API_KEY" not in os.environ:
|
|
os.environ["GEMINI_API_KEY"] = "dummy-key-for-tests"
|
|
|
|
# Configure asyncio for Windows compatibility
|
|
if sys.platform == "win32":
|
|
import asyncio
|
|
|
|
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
|
|
|
|
|
# Pytest configuration
|
|
def pytest_configure(config):
|
|
"""Configure pytest with custom markers"""
|
|
config.addinivalue_line("markers", "asyncio: mark test as async")
|