From 6feeb61e51c95b4374aaccf58b52ea1627c82179 Mon Sep 17 00:00:00 2001 From: Suren Khorenyan Date: Sat, 30 Dec 2023 22:49:34 +0300 Subject: [PATCH] Bot API 7.0 tests for dispatcher handle update removed_chat_boost --- tests/test_dispatcher/test_dispatcher.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tests/test_dispatcher/test_dispatcher.py b/tests/test_dispatcher/test_dispatcher.py index be0c68dc..8d3c81e6 100644 --- a/tests/test_dispatcher/test_dispatcher.py +++ b/tests/test_dispatcher/test_dispatcher.py @@ -20,6 +20,7 @@ from aiogram.types import ( Chat, ChatJoinRequest, ChatBoost, + ChatBoostRemoved, ChatBoostSourceGiveaway, ChatBoostUpdated, ChatMemberMember, @@ -508,6 +509,22 @@ class TestDispatcher: True, False, ), + pytest.param( + "removed_chat_boost", + Update( + update_id=42, + removed_chat_boost=ChatBoostRemoved( + chat=Chat(id=-42, type="channel"), + boost_id="qwerty", + remove_date=datetime.datetime.now(), + source=ChatBoostSourceGiveaway( + giveaway_message_id=77, + ), + ), + ), + True, + False, + ), ], ) async def test_listen_update(