Skip to content

Commit

Permalink
Refactor Tests for TelegramObject Classes with Subclasses (python-t…
Browse files Browse the repository at this point in the history
  • Loading branch information
Bibo-Joshi authored Feb 6, 2025
1 parent dfb0ae3 commit f9f1533
Show file tree
Hide file tree
Showing 8 changed files with 2,203 additions and 1,287 deletions.
3 changes: 2 additions & 1 deletion telegram/_chatmember.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
from telegram import constants
from telegram._telegramobject import TelegramObject
from telegram._user import User
from telegram._utils import enum
from telegram._utils.argumentparsing import de_json_optional
from telegram._utils.datetime import extract_tzinfo_from_defaults, from_timestamp
from telegram._utils.types import JSONDict
Expand Down Expand Up @@ -99,7 +100,7 @@ def __init__(
super().__init__(api_kwargs=api_kwargs)
# Required by all subclasses
self.user: User = user
self.status: str = status
self.status: str = enum.get_member(constants.ChatMemberStatus, status, status)

self._id_attrs = (self.user, self.status)

Expand Down
Loading

0 comments on commit f9f1533

Please sign in to comment.