mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Add tests for: message, chat, user, game, animation, document, photo
This commit is contained in:
parent
917c808b3d
commit
02596057a0
10 changed files with 309 additions and 24 deletions
|
|
@ -6,7 +6,14 @@ from .dataset import MESSAGE
|
|||
message = types.Message(**MESSAGE)
|
||||
|
||||
|
||||
def test_export():
|
||||
exported_chat = message.to_python()
|
||||
assert isinstance(exported_chat, dict)
|
||||
assert exported_chat == MESSAGE
|
||||
|
||||
|
||||
def test_message_id():
|
||||
assert hash(message) == MESSAGE['message_id']
|
||||
assert message.message_id == MESSAGE['message_id']
|
||||
assert message['message_id'] == MESSAGE['message_id']
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue