From c300195b4996f5d1fbf89bd11cb496b8208d8a17 Mon Sep 17 00:00:00 2001 From: eternnoir Date: Wed, 29 Nov 2017 13:59:47 +0800 Subject: [PATCH] Add provider_data . --- telebot/__init__.py | 2 +- tests/test_telebot.py | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/telebot/__init__.py b/telebot/__init__.py index ec48226..97dfa4b 100644 --- a/telebot/__init__.py +++ b/telebot/__init__.py @@ -889,7 +889,7 @@ class TeleBot: start_parameter, photo_url=None, photo_size=None, photo_width=None, photo_height=None, need_name=None, need_phone_number=None, need_email=None, need_shipping_address=None, is_flexible=None, - disable_notification=None, reply_to_message_id=None, reply_markup=None, provider_data=Noen): + disable_notification=None, reply_to_message_id=None, reply_markup=None, provider_data=None): result = apihelper.send_invoice(self.token, chat_id, title, description, invoice_payload, provider_token, currency, prices, start_parameter, photo_url, photo_size, photo_width, photo_height, diff --git a/tests/test_telebot.py b/tests/test_telebot.py index 3773ae4..b696bf4 100644 --- a/tests/test_telebot.py +++ b/tests/test_telebot.py @@ -410,3 +410,11 @@ class TestTeleBot: tb = telebot.TeleBot(TOKEN) ret_msg = tb.send_video_note(CHAT_ID, file_data) assert ret_msg.message_id + + def test_send_media_group(self): + tb = telebot.TeleBot(TOKEN) + img1 = 'https://i.imgur.com/CjXjcnU.png' + img2 = 'https://i.imgur.com/CjXjcnU.png' + medias = [types.InputMediaPhoto(img1, "View"), types.InputMediaPhoto(img2, "Dog")] + result = tb.send_media_group(CHAT_ID, medias) + assert len(result) == 2