Remove deprecated methods (#943)

* #941 Removed deprecated methods
This commit is contained in:
Alex Root Junior 2022-06-25 22:47:08 +03:00 committed by GitHub
parent 2c6d8ed5cb
commit fadb11515e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 3 additions and 345 deletions

View file

@ -1,13 +1,7 @@
from aiogram.types import MessageEntity
from tests.deprecated import check_deprecated
class TestMessageEntity:
def test_extract(self):
entity = MessageEntity(type="hashtag", length=4, offset=5)
assert entity.extract("#foo #bar #baz") == "#bar"
def test_get_text(self):
entity = MessageEntity(type="hashtag", length=4, offset=5)
with check_deprecated("3.2", exception=AttributeError):
assert entity.get_text("#foo #bar #baz") == "#bar"