3939class BotTest (BaseTest , unittest .TestCase ):
4040 """This object represents Tests for Telegram Bot."""
4141
42- @flaky
42+ @flaky ( 3 , 1 )
4343 @timeout (10 )
4444 def testGetMe (self ):
4545 '''Test the telegram.Bot getMe method'''
@@ -53,7 +53,7 @@ def testGetMe(self):
5353 self .assertEqual (bot .username , 'PythonTelegramBot' )
5454 self .assertEqual (bot .name , '@PythonTelegramBot' )
5555
56- @flaky
56+ @flaky ( 3 , 1 )
5757 @timeout (10 )
5858 def testSendMessage (self ):
5959 '''Test the telegram.Bot sendMessage method'''
@@ -65,7 +65,7 @@ def testSendMessage(self):
6565 self .assertEqual (message .text , u'Моё судно на воздушной подушке полно угрей' )
6666 self .assertTrue (isinstance (message .date , datetime ))
6767
68- @flaky
68+ @flaky ( 3 , 1 )
6969 @timeout (10 )
7070 def testGetUpdates (self ):
7171 '''Test the telegram.Bot getUpdates method'''
@@ -76,7 +76,7 @@ def testGetUpdates(self):
7676 self .assertTrue (self .is_json (updates [0 ].to_json ()))
7777 self .assertTrue (isinstance (updates [0 ], telegram .Update ))
7878
79- @flaky
79+ @flaky ( 3 , 1 )
8080 @timeout (10 )
8181 def testForwardMessage (self ):
8282 '''Test the telegram.Bot forwardMessage method'''
@@ -90,7 +90,7 @@ def testForwardMessage(self):
9090 self .assertEqual (message .forward_from .username , 'leandrotoledo' )
9191 self .assertTrue (isinstance (message .forward_date , datetime ))
9292
93- @flaky
93+ @flaky ( 3 , 1 )
9494 @timeout (10 )
9595 def testSendPhoto (self ):
9696 '''Test the telegram.Bot sendPhoto method'''
@@ -103,7 +103,7 @@ def testSendPhoto(self):
103103 self .assertEqual (message .photo [0 ].file_size , 1451 )
104104 self .assertEqual (message .caption , 'testSendPhoto' )
105105
106- @flaky
106+ @flaky ( 3 , 1 )
107107 @timeout (10 )
108108 def testResendPhoto (self ):
109109 '''Test the telegram.Bot sendPhoto method'''
@@ -114,7 +114,7 @@ def testResendPhoto(self):
114114 self .assertTrue (self .is_json (message .to_json ()))
115115 self .assertEqual (message .photo [0 ].file_id , 'AgADAQADyKcxGx8j9Qdp6d-gpUsw4Gja1i8ABEVJsVqQk8LfJ3wAAgI' )
116116
117- @flaky
117+ @flaky ( 3 , 1 )
118118 @timeout (10 )
119119 def testSendJPGURLPhoto (self ):
120120 '''Test the telegram.Bot sendPhoto method'''
@@ -125,7 +125,7 @@ def testSendJPGURLPhoto(self):
125125 self .assertTrue (self .is_json (message .to_json ()))
126126 self .assertEqual (message .photo [0 ].file_size , 822 )
127127
128- @flaky
128+ @flaky ( 3 , 1 )
129129 @timeout (10 )
130130 def testSendPNGURLPhoto (self ):
131131 '''Test the telegram.Bot sendPhoto method'''
@@ -136,7 +136,7 @@ def testSendPNGURLPhoto(self):
136136 self .assertTrue (self .is_json (message .to_json ()))
137137 self .assertEqual (message .photo [0 ].file_size , 684 )
138138
139- @flaky
139+ @flaky ( 3 , 1 )
140140 @timeout (10 )
141141 def testSendGIFURLPhoto (self ):
142142 '''Test the telegram.Bot sendPhoto method'''
@@ -147,7 +147,7 @@ def testSendGIFURLPhoto(self):
147147 self .assertTrue (self .is_json (message .to_json ()))
148148 self .assertEqual (message .photo [0 ].file_size , 684 )
149149
150- @flaky
150+ @flaky ( 3 , 1 )
151151 @timeout (10 )
152152 def testSendChatAction (self ):
153153 '''Test the telegram.Bot sendChatAction method'''
@@ -156,7 +156,7 @@ def testSendChatAction(self):
156156 self ._bot .sendChatAction (action = telegram .ChatAction .TYPING ,
157157 chat_id = self ._chat_id )
158158
159- @flaky
159+ @flaky ( 3 , 1 )
160160 @timeout (10 )
161161 def testGetUserProfilePhotos (self ):
162162 '''Test the telegram.Bot getUserProfilePhotos method'''
0 commit comments