update provider chatBase (#48)

* add get_bot iterator

* get_bot is separate application

* Update provider chatBase
This commit is contained in:
Dmitry Afanasyev
2023-10-30 20:02:45 +03:00
committed by GitHub
parent 93690d2e14
commit e929717b15
5 changed files with 40 additions and 22 deletions

View File

@@ -254,7 +254,14 @@ async def test_ask_question_action(
await main_application.bot_app.application.process_update(
update=Update.de_json(data=bot_update, bot=main_application.bot_app.bot)
)
assert_that(mocked_send_message.call_args.kwargs).is_equal_to(
assert_that(mocked_send_message.call_args_list[0].kwargs).is_equal_to(
{
"text": "Пожалуйста, подождите, ответ в среднем занимает 10-15 секунд",
"chat_id": bot_update["message"]["chat"]["id"],
},
include=["text", "chat_id"],
)
assert_that(mocked_send_message.call_args_list[1].kwargs).is_equal_to(
{
"text": "Привет! Как я могу помочь вам сегодня?",
"chat_id": bot_update["message"]["chat"]["id"],