mirror of
https://github.com/Balshgit/mosgortrans.git
synced 2025-09-11 13:00:40 +03:00
19 lines
403 B
Python
19 lines
403 B
Python
import pytest
|
|
from aiogram import Bot, types
|
|
from app.tests.conftest import FakeTelegram
|
|
from app.tests.factories import UserFactory
|
|
|
|
pytestmark = [
|
|
pytest.mark.asyncio,
|
|
]
|
|
|
|
|
|
async def test_parse_site(bot: Bot) -> None:
|
|
tg_user = UserFactory().as_dict()
|
|
user = types.User(**tg_user)
|
|
|
|
async with FakeTelegram(message_data=tg_user):
|
|
result = await bot.me
|
|
|
|
assert result == user
|