mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Test changes
This commit is contained in:
parent
c7a0d75c39
commit
97df4ba383
1 changed files with 6 additions and 0 deletions
|
|
@ -43,3 +43,9 @@ class TestStorages:
|
|||
"foo": "bar",
|
||||
"baz": "spam",
|
||||
}
|
||||
|
||||
async def test_get_value(self, bot: MockedBot, storage: BaseStorage, storage_key: StorageKey):
|
||||
await storage.set_data(key=storage_key, data={"hello": "world"})
|
||||
assert await storage.get_value(key=storage_key, data_key="hello") == "world"
|
||||
assert await storage.get_value(key=storage_key, data_key="12345") is None
|
||||
assert await storage.get_value(key=storage_key, data_key="qwerty", default=42) == 42
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue