X Tutup
Skip to content

Commit 32a7872

Browse files
committed
yapf fixes
1 parent 04feeef commit 32a7872

File tree

2 files changed

+5
-27
lines changed

2 files changed

+5
-27
lines changed

telegram/animation.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@ class Animation(TelegramObject):
3535
3636
"""
3737

38-
def __init__(self,
39-
file_id,
40-
**kwargs):
38+
def __init__(self, file_id, **kwargs):
4139
self.file_id = file_id
4240
self.thumb = kwargs.get('thumb')
4341
self.file_name = kwargs.get('file_name')

tests/test_game.py

Lines changed: 4 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -34,25 +34,10 @@ class GameTest(BaseTest, unittest.TestCase):
3434
def setUp(self):
3535
self.title = 'Python-telegram-bot Test Game'
3636
self.description = 'description'
37-
self.photo = [
38-
{
39-
'width': 640,
40-
'height': 360,
41-
'file_id': 'Blah',
42-
'file_size': 0
43-
}
44-
]
37+
self.photo = [{'width': 640, 'height': 360, 'file_id': 'Blah', 'file_size': 0}]
4538
self.text = 'Other description'
46-
self.text_entities = [
47-
{
48-
'offset': 13,
49-
'length': 17,
50-
'type': telegram.MessageEntity.URL
51-
}
52-
]
53-
self.animation = {
54-
'file_id': 'Blah'
55-
}
39+
self.text_entities = [{'offset': 13, 'length': 17, 'type': telegram.MessageEntity.URL}]
40+
self.animation = {'file_id': 'Blah'}
5641

5742
self.json_dict = {
5843
'title': self.title,
@@ -120,12 +105,7 @@ class AnimationTest(BaseTest, unittest.TestCase):
120105

121106
def setUp(self):
122107
self.file_id = 'thisisafileid'
123-
self.thumb = {
124-
'width': 640,
125-
'height': 360,
126-
'file_id': 'Blah',
127-
'file_size': 0
128-
}
108+
self.thumb = {'width': 640, 'height': 360, 'file_id': 'Blah', 'file_size': 0}
129109
self.file_name = 'File name'
130110
self.mime_type = 'something/gif'
131111
self.file_size = 42

0 commit comments

Comments
 (0)
X Tutup