Skip to content

Commit f5a6fa8

Browse files
authored
Bump python-telegram-bot to 22.5 (home-assistant#155134)
1 parent 3c75191 commit f5a6fa8

File tree

5 files changed

+17
-5
lines changed

5 files changed

+17
-5
lines changed

homeassistant/components/telegram_bot/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@
88
"iot_class": "cloud_push",
99
"loggers": ["telegram"],
1010
"quality_scale": "bronze",
11-
"requirements": ["python-telegram-bot[socks]==21.5"]
11+
"requirements": ["python-telegram-bot[socks]==22.1"]
1212
}

requirements_all.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

requirements_test_all.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/components/telegram_bot/conftest.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,15 @@
66
from unittest.mock import AsyncMock, patch
77

88
import pytest
9-
from telegram import Bot, Chat, ChatFullInfo, Message, User, WebhookInfo
9+
from telegram import (
10+
AcceptedGiftTypes,
11+
Bot,
12+
Chat,
13+
ChatFullInfo,
14+
Message,
15+
User,
16+
WebhookInfo,
17+
)
1018
from telegram.constants import AccentColor, ChatType
1119

1220
from homeassistant.components.telegram_bot import (
@@ -106,6 +114,7 @@ def mock_external_calls() -> Generator[None]:
106114
type="PRIVATE",
107115
max_reaction_count=100,
108116
accent_color_id=AccentColor.COLOR_000,
117+
accepted_gift_types=AcceptedGiftTypes(True, True, True, True),
109118
)
110119
test_user = User(123456, "Testbot", True, "mock last name", "mock username")
111120
message = Message(

tests/components/telegram_bot/test_config_flow.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
from unittest.mock import AsyncMock, patch
44

5-
from telegram import ChatFullInfo, User
5+
from telegram import AcceptedGiftTypes, ChatFullInfo, User
66
from telegram.constants import AccentColor
77
from telegram.error import BadRequest, InvalidToken, NetworkError
88

@@ -390,6 +390,7 @@ async def test_subentry_flow(
390390
type="PRIVATE",
391391
max_reaction_count=100,
392392
accent_color_id=AccentColor.COLOR_000,
393+
accepted_gift_types=AcceptedGiftTypes(True, True, True, True),
393394
),
394395
):
395396
result = await hass.config_entries.subentries.async_configure(
@@ -458,6 +459,7 @@ async def test_subentry_flow_chat_error(
458459
type="PRIVATE",
459460
max_reaction_count=100,
460461
accent_color_id=AccentColor.COLOR_000,
462+
accepted_gift_types=AcceptedGiftTypes(True, True, True, True),
461463
),
462464
):
463465
result = await hass.config_entries.subentries.async_configure(
@@ -534,6 +536,7 @@ async def test_import_multiple(
534536
type="PRIVATE",
535537
max_reaction_count=100,
536538
accent_color_id=AccentColor.COLOR_000,
539+
accepted_gift_types=AcceptedGiftTypes(True, True, True, True),
537540
),
538541
),
539542
):

0 commit comments

Comments
 (0)