mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-11-30 04:02:49 +01:00
Update filter test
This commit is contained in:
parent
2b871e6f93
commit
01f3d88788
1 changed files with 3 additions and 5 deletions
|
@ -254,12 +254,10 @@ class FiltersTest(BaseTest, unittest.TestCase):
|
||||||
self.assertTrue((Filters.text & (Filters.forwarded | Filters.entity(MessageEntity.MENTION))
|
self.assertTrue((Filters.text & (Filters.forwarded | Filters.entity(MessageEntity.MENTION))
|
||||||
)(self.message))
|
)(self.message))
|
||||||
|
|
||||||
self.assertRegexpMatches(
|
self.assertEqual(
|
||||||
str((Filters.text & (Filters.forwarded | Filters.entity(MessageEntity.MENTION)))),
|
str((Filters.text & (Filters.forwarded | Filters.entity(MessageEntity.MENTION)))),
|
||||||
r"<telegram.ext.filters.MergedFilter consisting of <telegram.ext.filters.(Filters.)?_"
|
'<Filters.text and <Filters.forwarded or Filters.entity(mention)>>'
|
||||||
r"Text object at .*?> and <telegram.ext.filters.MergedFilter consisting of "
|
)
|
||||||
r"<telegram.ext.filters.(Filters.)?_Forwarded object at .*?> or "
|
|
||||||
r"<telegram.ext.filters.(Filters.)?entity object at .*?>>>")
|
|
||||||
|
|
||||||
def test_inverted_filters(self):
|
def test_inverted_filters(self):
|
||||||
self.message.text = '/test'
|
self.message.text = '/test'
|
||||||
|
|
Loading…
Reference in a new issue