Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from collections.abc import AsyncGenerator
from collections.abc import AsyncGenerator, Generator
from datetime import UTC, datetime, timedelta
from unittest.mock import AsyncMock, patch
from uuid import UUID

import pytest
Expand All @@ -26,6 +27,12 @@
DATABASE_URL = "sqlite+aiosqlite:///:memory:"


@pytest.fixture(autouse=True)
def mock_send_email() -> Generator[AsyncMock, None, None]:
with patch("app.core.email.send_email", new_callable=AsyncMock) as mock:
yield mock


@pytest.fixture
async def engine() -> AsyncGenerator[AsyncEngine, None]:
_engine = create_async_engine(
Expand Down
Loading