aiogram/tests/test_api/test_client
JRoot Junior b2b2fcff70
Add context manager support for bot client
The bot client now supports the context manager protocol, providing automatic resource management. This enhancement helps to automatically close the session when leaving the context, which cleans up resources better. The documentation and tests have been updated accordingly to illustrate this new feature. Moreover, an example of usage without a dispatcher has been provided to clarify its use in simple cases.
2024-04-22 23:37:34 +03:00
..
test_session Added full support of Bot API 7.2 (#1444) 2024-04-22 13:48:49 +03:00
__init__.py Add tests for BaseSession and TelegramAPIServer 2019-11-16 00:52:18 +02:00
test_api_server.py Rework session DI and files path wrapper 2021-12-12 18:15:36 +02:00
test_bot.py Add context manager support for bot client 2024-04-22 23:37:34 +03:00
test_context_controller.py PoC: Bot instance inside method shortcuts using pydantic Validation Context (#1210) 2023-07-11 23:17:26 +03:00
test_default.py Fixed poll answer FSM context (#1436) 2024-03-10 16:18:41 +02:00