mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Add MediaGroupBuilder for media group construction (#1293)
Implemented a MediaGroupBuilder class in 'aiogram/utils/media_group.py' to help construct media groups. The class supports addition of different media types (audio, photo, video, document) to the media group with a maximum limit of 10 files. The functionality is demonstrated and usage is documented in 'docs/utils/media_group.rst'. Added related test cases in 'tests/test_utils/test_media_group.py'. This is to streamline and simplify the process of media group creation
This commit is contained in:
parent
8fd110cdd1
commit
5cf8d7b565
6 changed files with 509 additions and 1 deletions
|
|
@ -3,7 +3,7 @@ from unittest.mock import sentinel
|
|||
import pytest
|
||||
|
||||
from aiogram.methods import GetMe, TelegramMethod
|
||||
from aiogram.types import User, TelegramObject
|
||||
from aiogram.types import TelegramObject, User
|
||||
from tests.mocked_bot import MockedBot
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue