aiogram/tests
kievzenit 99fa2460da
Migrate motor to pymongo (#1705)
* migrated mongo storage from using deprecated motor to PyMongo

* added storages to __init__.py file to improve DX

* changelog file created

* Revert "added storages to __init__.py file to improve DX"

This reverts commit 5d0f6a9dfb.

* added optional dependency to pymongo to pyproject.toml

* Revert "migrated mongo storage from using deprecated motor to PyMongo"

This reverts commit 1c0207e1d1.

* added deprecation warning to mongo storage

* created pymongo storage

* added entry for PyMongoStorage to documentation in fsm.storages

* updated changelog to have information about how to migrate from MongoStorage to PyMongoStorage

* added test for pymongo storage (copied from mongo storage test)

* fixed formatting using black and isort

* fixed bug in close method of PyMongoStorage (client close method was not awaited)

* added test for PyMongoStorage that checks if storage could be properly closed

* pymongo package changed to be lower case in PyMongoStorage

* added fixture registration for pymongo storage

* test for pymongo is now using proper test fixtures

* removed redundant call to get_data, because we have checked this condition in the previous line

* added more tests to pymongo test, to check for all possible cases of using update_data method

* fixed PyMongoStorage update_data method implementation

* added pymongo tests to test_storages

* fixed pymongo tests, update_data method should not delete document when {} was passed

* Revert "fixed PyMongoStorage update_data method implementation"

This reverts commit 86170e1cb9.

* fixed linting issues in PyMongoStorage

* changed allowed versions of pymongo, to be compatible with motor

* pinned the upper version of pymongo to <4.11
2025-08-17 19:16:47 +03:00
..
data/locales Dev 3.x i18n & improvements (#696) 2021-09-22 00:52:38 +03:00
test_api Added full support for the Bot API 9.2 (#1720) 2025-08-17 19:07:58 +03:00
test_dispatcher Add semaphore support for limiting concurrent updates (#1670) 2025-04-12 23:30:02 +03:00
test_filters Fix handling of default empty string ("") in CallbackData filter (#1493) 2025-03-11 00:14:13 +02:00
test_flags Dev 3.x flat package (#961) 2022-08-14 01:07:52 +03:00
test_fsm Migrate motor to pymongo (#1705) 2025-08-17 19:16:47 +03:00
test_handler Removed the use of the context instance (Bot.get_current) from all placements that were used previously. (#1230) 2023-07-28 22:23:32 +03:00
test_issues fix: ensure middleware data is passed to scene entry handler (#1674) 2025-04-17 00:42:39 +03:00
test_utils Support validating init data using only bot id. (#1715) 2025-08-17 19:15:23 +03:00
test_webhook fix empty response into webhook (#1665) 2025-04-05 20:31:42 +03:00
__init__.py Update tests and small refactoring 2019-11-16 22:32:26 +02:00
conftest.py Migrate motor to pymongo (#1705) 2025-08-17 19:16:47 +03:00
deprecated.py Upgrade architecture + 5.0 Bot API (#469) 2021-01-26 21:20:52 +02:00
docker-compose.yml Added MongoStorage for FSM (#1434) 2024-05-07 22:42:31 +03:00
mocked_bot.py "Add get_mounted_bot function and improve model comparison in tests" 2023-07-16 22:46:45 +03:00