Best Python code snippet using localstack_python
bot_test.py
Source:bot_test.py
...12 def testStart(self):13 try:14 client.send_message('@schfratorBot', '/start')15 time.sleep(2)16 messages = client.get_messages('@schfratorBot')17 for message in client.get_messages('@schfratorBot', limit=1):18 m = message.message19 self.assertEqual(len(messages), 1)20 text = 'ÐÑивеÑ!Я боÑ, коÑоÑÑй Ð¿Ð¾Ð¼Ð¾Ð¶ÐµÑ Ñебе заÑиÑÑоваÑÑ/ÑаÑÑиÑÑоваÑÑ Ð¿Ð¾ÑÐ»Ð°Ð½Ð¸Ñ Ñ Ð¿Ð¾Ð¼Ð¾ÑÑÑ ÑазлиÑнÑÑ
ÑиÑÑов.ÐапиÑи /'21 self.assertRegex(m, text)22 except:23 self.assertFalse(True)24 def testAtbasha(self):25 try:26 client.send_message('@schfratorBot', '/atbatsha')27 time.sleep(2)28 messages = client.get_messages('@schfratorBot')29 for message in client.get_messages('@schfratorBot', limit=1):30 m = message.message31 self.assertEqual(len(messages), 1)32 text = 'ÐÑбÑан ÑиÑÑ ÐÑбаÑÑа\n\nЯзÑк ввода - английÑкий\n\nФÑнкÑии: ÑиÑÑование\n\nÐведиÑе ÑекÑÑ:'33 self.assertRegex(m, text)34 client.send_message('@schfratorBot', 'abc')35 time.sleep(2)36 messages = client.get_messages('@schfratorBot')37 for message in client.get_messages('@schfratorBot', limit=1):38 m = message.message39 self.assertEqual(len(messages), 1)40 text = 'РезÑлÑÑаÑ:zyx'41 self.assertRegex(m, text)42 except:43 self.assertFalse(True)44 def testCezarSchifrator(self):45 try:46 client.send_message('@schfratorBot', '/cezarius')47 time.sleep(2)48 messages = client.get_messages('@schfratorBot')49 for message in client.get_messages('@schfratorBot', limit=1):50 m = message.message51 self.assertEqual(len(messages), 1)52 text = 'ÐÑбÑан ÑиÑÑ Ð¦ÐµÐ·Ð°ÑÑ\n\nЯзÑк ввода - ÑÑÑÑкий\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование\n\nÐведиÑе Ш ÑÑÐ¾Ð±Ñ Ð·Ð°ÑиÑÑоваÑÑ ÑообÑение, Ð ÑÑÐ¾Ð±Ñ ÑаÑÑиÑÑоваÑÑ'53 self.assertRegex(m, text)54 client.send_message('@schfratorBot', 'Ш')55 time.sleep(2)56 messages = client.get_messages('@schfratorBot')57 for message in client.get_messages('@schfratorBot', limit=1):58 m = message.message59 self.assertEqual(len(messages), 1)60 text = 'ÐведиÑе ÑекÑÑ:'61 self.assertRegex(m, text)62 client.send_message('@schfratorBot', 'абоба34')63 time.sleep(2)64 messages = client.get_messages('@schfratorBot')65 for message in client.get_messages('@schfratorBot', limit=1):66 m = message.message67 self.assertEqual(len(messages), 1)68 text = 'ÐведиÑе клÑÑ:'69 self.assertRegex(m, text)70 client.send_message('@schfratorBot', '5')71 time.sleep(2)72 messages = client.get_messages('@schfratorBot')73 for message in client.get_messages('@schfratorBot', limit=1):74 m = message.message75 self.assertEqual(len(messages), 1)76 text = 'РезÑлÑÑаÑ:еÑÑÑе34'77 self.assertRegex(m, text)78 except:79 self.assertFalse(True)80 def testCezarRashifrator(self):81 try:82 client.send_message('@schfratorBot', '/cezarius')83 time.sleep(2)84 messages = client.get_messages('@schfratorBot')85 for message in client.get_messages('@schfratorBot', limit=1):86 m = message.message87 self.assertEqual(len(messages), 1)88 text = 'ÐÑбÑан ÑиÑÑ Ð¦ÐµÐ·Ð°ÑÑ\n\nЯзÑк ввода - ÑÑÑÑкий\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование\n\nÐведиÑе Ш ÑÑÐ¾Ð±Ñ Ð·Ð°ÑиÑÑоваÑÑ ÑообÑение, Ð ÑÑÐ¾Ð±Ñ ÑаÑÑиÑÑоваÑÑ'89 self.assertRegex(m, text)90 client.send_message('@schfratorBot', 'Ð ')91 time.sleep(2)92 messages = client.get_messages('@schfratorBot')93 for message in client.get_messages('@schfratorBot', limit=1):94 m = message.message95 self.assertEqual(len(messages), 1)96 text = 'ÐведиÑе ÑекÑÑ:'97 self.assertRegex(m, text)98 client.send_message('@schfratorBot', 'еÑÑÑе34')99 time.sleep(2)100 messages = client.get_messages('@schfratorBot')101 for message in client.get_messages('@schfratorBot', limit=1):102 m = message.message103 self.assertEqual(len(messages), 1)104 text = 'ÐведиÑе клÑÑ:'105 self.assertRegex(m, text)106 client.send_message('@schfratorBot', '5')107 time.sleep(2)108 messages = client.get_messages('@schfratorBot')109 for message in client.get_messages('@schfratorBot', limit=1):110 m = message.message111 self.assertEqual(len(messages), 1)112 text = 'РезÑлÑÑаÑ:абоба34'113 self.assertRegex(m, text)114 except:115 self.assertFalse(True)116 def testVisionerSCHrusPOVstr(self):117 try:118 client.send_message('@schfratorBot', '/visioner')119 time.sleep(2)120 messages = client.get_messages('@schfratorBot')121 for message in client.get_messages('@schfratorBot', limit=1):122 m = message.message123 self.assertEqual(len(messages), 1)124 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'125 self.assertRegex(m, text)126 client.send_message('@schfratorBot', 'ÑÑÑÑ')127 time.sleep(2)128 messages = client.get_messages('@schfratorBot')129 for message in client.get_messages('@schfratorBot', limit=1):130 m = message.message131 self.assertEqual(len(messages), 1)132 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'133 self.assertRegex(m, text)134 client.send_message('@schfratorBot', 'ÑиÑÑ')135 time.sleep(2)136 messages = client.get_messages('@schfratorBot')137 for message in client.get_messages('@schfratorBot', limit=1):138 m = message.message139 self.assertEqual(len(messages), 1)140 text = 'ÐведиÑе ÑекÑÑ:'141 self.assertRegex(m, text)142 client.send_message('@schfratorBot', 'абоба')143 time.sleep(2)144 messages = client.get_messages('@schfratorBot')145 for message in client.get_messages('@schfratorBot', limit=1):146 m = message.message147 self.assertEqual(len(messages), 1)148 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'149 self.assertRegex(m, text)150 client.send_message('@schfratorBot', 'мак')151 time.sleep(2)152 messages = client.get_messages('@schfratorBot')153 for message in client.get_messages('@schfratorBot', limit=1):154 m = message.message155 self.assertEqual(len(messages), 1)156 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'157 self.assertRegex(m, text)158 client.send_message('@schfratorBot', 'повÑоÑ')159 time.sleep(2)160 messages = client.get_messages('@schfratorBot')161 for message in client.get_messages('@schfratorBot', limit=1):162 m = message.message163 self.assertEqual(len(messages), 1)164 text = 'СделаÑÑ ÑÑÑоÑнÑми?'165 self.assertRegex(m, text)166 client.send_message('@schfratorBot', 'да')167 time.sleep(2)168 messages = client.get_messages('@schfratorBot')169 for message in client.get_messages('@schfratorBot', limit=1):170 m = message.message171 self.assertEqual(len(messages), 1)172 text = 'РезÑлÑÑаÑ:мбÑна'173 self.assertRegex(m, text)174 except:175 self.assertFalse(True)176 def testVisionerRASHrusPOVstr(self):177 try:178 client.send_message('@schfratorBot', '/visioner')179 time.sleep(2)180 messages = client.get_messages('@schfratorBot')181 for message in client.get_messages('@schfratorBot', limit=1):182 m = message.message183 self.assertEqual(len(messages), 1)184 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'185 self.assertRegex(m, text)186 client.send_message('@schfratorBot', 'ÑÑÑÑ')187 time.sleep(2)188 messages = client.get_messages('@schfratorBot')189 for message in client.get_messages('@schfratorBot', limit=1):190 m = message.message191 self.assertEqual(len(messages), 1)192 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'193 self.assertRegex(m, text)194 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')195 time.sleep(2)196 messages = client.get_messages('@schfratorBot')197 for message in client.get_messages('@schfratorBot', limit=1):198 m = message.message199 self.assertEqual(len(messages), 1)200 text = 'ÐведиÑе ÑекÑÑ:'201 self.assertRegex(m, text)202 client.send_message('@schfratorBot', 'мбÑна')203 time.sleep(2)204 messages = client.get_messages('@schfratorBot')205 for message in client.get_messages('@schfratorBot', limit=1):206 m = message.message207 self.assertEqual(len(messages), 1)208 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'209 self.assertRegex(m, text)210 client.send_message('@schfratorBot', 'мак')211 time.sleep(2)212 messages = client.get_messages('@schfratorBot')213 for message in client.get_messages('@schfratorBot', limit=1):214 m = message.message215 self.assertEqual(len(messages), 1)216 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'217 self.assertRegex(m, text)218 client.send_message('@schfratorBot', 'повÑоÑ')219 time.sleep(2)220 messages = client.get_messages('@schfratorBot')221 for message in client.get_messages('@schfratorBot', limit=1):222 m = message.message223 self.assertEqual(len(messages), 1)224 text = 'СделаÑÑ ÑÑÑоÑнÑми?'225 self.assertRegex(m, text)226 client.send_message('@schfratorBot', 'да')227 time.sleep(2)228 messages = client.get_messages('@schfratorBot')229 for message in client.get_messages('@schfratorBot', limit=1):230 m = message.message231 self.assertEqual(len(messages), 1)232 text = 'РезÑлÑÑаÑ:абоба'233 self.assertRegex(m, text)234 except:235 self.assertFalse(True)236 def testVisionerSCHengPOVstr(self):237 try:238 client.send_message('@schfratorBot', '/visioner')239 time.sleep(2)240 messages = client.get_messages('@schfratorBot')241 for message in client.get_messages('@schfratorBot', limit=1):242 m = message.message243 self.assertEqual(len(messages), 1)244 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'245 self.assertRegex(m, text)246 client.send_message('@schfratorBot', 'англ')247 time.sleep(2)248 messages = client.get_messages('@schfratorBot')249 for message in client.get_messages('@schfratorBot', limit=1):250 m = message.message251 self.assertEqual(len(messages), 1)252 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'253 self.assertRegex(m, text)254 client.send_message('@schfratorBot', 'ÑиÑÑ')255 time.sleep(2)256 messages = client.get_messages('@schfratorBot')257 for message in client.get_messages('@schfratorBot', limit=1):258 m = message.message259 self.assertEqual(len(messages), 1)260 text = 'ÐведиÑе ÑекÑÑ:'261 self.assertRegex(m, text)262 client.send_message('@schfratorBot', 'aboba')263 time.sleep(2)264 messages = client.get_messages('@schfratorBot')265 for message in client.get_messages('@schfratorBot', limit=1):266 m = message.message267 self.assertEqual(len(messages), 1)268 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'269 self.assertRegex(m, text)270 client.send_message('@schfratorBot', 'mac')271 time.sleep(2)272 messages = client.get_messages('@schfratorBot')273 for message in client.get_messages('@schfratorBot', limit=1):274 m = message.message275 self.assertEqual(len(messages), 1)276 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'277 self.assertRegex(m, text)278 client.send_message('@schfratorBot', 'повÑоÑ')279 time.sleep(2)280 messages = client.get_messages('@schfratorBot')281 for message in client.get_messages('@schfratorBot', limit=1):282 m = message.message283 self.assertEqual(len(messages), 1)284 text = 'СделаÑÑ ÑÑÑоÑнÑми?'285 self.assertRegex(m, text)286 client.send_message('@schfratorBot', 'да')287 time.sleep(2)288 messages = client.get_messages('@schfratorBot')289 for message in client.get_messages('@schfratorBot', limit=1):290 m = message.message291 self.assertEqual(len(messages), 1)292 text = 'РезÑлÑÑаÑ:mbqna'293 self.assertRegex(m, text)294 except:295 self.assertFalse(True)296 def testVisionerRASHengPOVstr(self):297 try:298 client.send_message('@schfratorBot', '/visioner')299 time.sleep(2)300 messages = client.get_messages('@schfratorBot')301 for message in client.get_messages('@schfratorBot', limit=1):302 m = message.message303 self.assertEqual(len(messages), 1)304 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'305 self.assertRegex(m, text)306 client.send_message('@schfratorBot', 'англ')307 time.sleep(2)308 messages = client.get_messages('@schfratorBot')309 for message in client.get_messages('@schfratorBot', limit=1):310 m = message.message311 self.assertEqual(len(messages), 1)312 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'313 self.assertRegex(m, text)314 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')315 time.sleep(2)316 messages = client.get_messages('@schfratorBot')317 for message in client.get_messages('@schfratorBot', limit=1):318 m = message.message319 self.assertEqual(len(messages), 1)320 text = 'ÐведиÑе ÑекÑÑ:'321 self.assertRegex(m, text)322 client.send_message('@schfratorBot', 'mbqna')323 time.sleep(2)324 messages = client.get_messages('@schfratorBot')325 for message in client.get_messages('@schfratorBot', limit=1):326 m = message.message327 self.assertEqual(len(messages), 1)328 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'329 self.assertRegex(m, text)330 client.send_message('@schfratorBot', 'mac')331 time.sleep(2)332 messages = client.get_messages('@schfratorBot')333 for message in client.get_messages('@schfratorBot', limit=1):334 m = message.message335 self.assertEqual(len(messages), 1)336 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'337 self.assertRegex(m, text)338 client.send_message('@schfratorBot', 'повÑоÑ')339 time.sleep(2)340 messages = client.get_messages('@schfratorBot')341 for message in client.get_messages('@schfratorBot', limit=1):342 m = message.message343 self.assertEqual(len(messages), 1)344 text = 'СделаÑÑ ÑÑÑоÑнÑми?'345 self.assertRegex(m, text)346 client.send_message('@schfratorBot', 'да')347 time.sleep(2)348 messages = client.get_messages('@schfratorBot')349 for message in client.get_messages('@schfratorBot', limit=1):350 m = message.message351 self.assertEqual(len(messages), 1)352 text = 'РезÑлÑÑаÑ:aboba'353 self.assertRegex(m, text)354 except:355 self.assertFalse(True)356 def testVisionerSCHrusSAMOstr(self):357 try:358 client.send_message('@schfratorBot', '/visioner')359 time.sleep(2)360 messages = client.get_messages('@schfratorBot')361 for message in client.get_messages('@schfratorBot', limit=1):362 m = message.message363 self.assertEqual(len(messages), 1)364 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'365 self.assertRegex(m, text)366 client.send_message('@schfratorBot', 'ÑÑÑÑ')367 time.sleep(2)368 messages = client.get_messages('@schfratorBot')369 for message in client.get_messages('@schfratorBot', limit=1):370 m = message.message371 self.assertEqual(len(messages), 1)372 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'373 self.assertRegex(m, text)374 client.send_message('@schfratorBot', 'ÑиÑÑ')375 time.sleep(2)376 messages = client.get_messages('@schfratorBot')377 for message in client.get_messages('@schfratorBot', limit=1):378 m = message.message379 self.assertEqual(len(messages), 1)380 text = 'ÐведиÑе ÑекÑÑ:'381 self.assertRegex(m, text)382 client.send_message('@schfratorBot', 'абоба')383 time.sleep(2)384 messages = client.get_messages('@schfratorBot')385 for message in client.get_messages('@schfratorBot', limit=1):386 m = message.message387 self.assertEqual(len(messages), 1)388 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'389 self.assertRegex(m, text)390 client.send_message('@schfratorBot', 'мак')391 time.sleep(2)392 messages = client.get_messages('@schfratorBot')393 for message in client.get_messages('@schfratorBot', limit=1):394 m = message.message395 self.assertEqual(len(messages), 1)396 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'397 self.assertRegex(m, text)398 client.send_message('@schfratorBot', 'Ñамо')399 time.sleep(2)400 messages = client.get_messages('@schfratorBot')401 for message in client.get_messages('@schfratorBot', limit=1):402 m = message.message403 self.assertEqual(len(messages), 1)404 text = 'СделаÑÑ ÑÑÑоÑнÑми?'405 self.assertRegex(m, text)406 client.send_message('@schfratorBot', 'да')407 time.sleep(2)408 messages = client.get_messages('@schfratorBot')409 for message in client.get_messages('@schfratorBot', limit=1):410 m = message.message411 self.assertEqual(len(messages), 1)412 text = 'РезÑлÑÑаÑ:мбÑбб'413 self.assertRegex(m, text)414 except:415 self.assertFalse(True)416 def testVisionerRASHrusSAMOstr(self):417 try:418 client.send_message('@schfratorBot', '/visioner')419 time.sleep(2)420 messages = client.get_messages('@schfratorBot')421 for message in client.get_messages('@schfratorBot', limit=1):422 m = message.message423 self.assertEqual(len(messages), 1)424 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'425 self.assertRegex(m, text)426 client.send_message('@schfratorBot', 'ÑÑÑÑ')427 time.sleep(2)428 messages = client.get_messages('@schfratorBot')429 for message in client.get_messages('@schfratorBot', limit=1):430 m = message.message431 self.assertEqual(len(messages), 1)432 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'433 self.assertRegex(m, text)434 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')435 time.sleep(2)436 messages = client.get_messages('@schfratorBot')437 for message in client.get_messages('@schfratorBot', limit=1):438 m = message.message439 self.assertEqual(len(messages), 1)440 text = 'ÐведиÑе ÑекÑÑ:'441 self.assertRegex(m, text)442 client.send_message('@schfratorBot', 'мбÑбб')443 time.sleep(2)444 messages = client.get_messages('@schfratorBot')445 for message in client.get_messages('@schfratorBot', limit=1):446 m = message.message447 self.assertEqual(len(messages), 1)448 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'449 self.assertRegex(m, text)450 client.send_message('@schfratorBot', 'макаб')451 time.sleep(2)452 messages = client.get_messages('@schfratorBot')453 for message in client.get_messages('@schfratorBot', limit=1):454 m = message.message455 self.assertEqual(len(messages), 1)456 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'457 self.assertRegex(m, text)458 client.send_message('@schfratorBot', 'Ñамо')459 time.sleep(2)460 messages = client.get_messages('@schfratorBot')461 for message in client.get_messages('@schfratorBot', limit=1):462 m = message.message463 self.assertEqual(len(messages), 1)464 text = 'СделаÑÑ ÑÑÑоÑнÑми?'465 self.assertRegex(m, text)466 client.send_message('@schfratorBot', 'да')467 time.sleep(2)468 messages = client.get_messages('@schfratorBot')469 for message in client.get_messages('@schfratorBot', limit=1):470 m = message.message471 self.assertEqual(len(messages), 1)472 text = 'РезÑлÑÑаÑ:абоба'473 self.assertRegex(m, text)474 except:475 self.assertFalse(True)476 def testVisionerSCHengSAMOstr(self):477 try:478 client.send_message('@schfratorBot', '/visioner')479 time.sleep(2)480 messages = client.get_messages('@schfratorBot')481 for message in client.get_messages('@schfratorBot', limit=1):482 m = message.message483 self.assertEqual(len(messages), 1)484 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'485 self.assertRegex(m, text)486 client.send_message('@schfratorBot', 'англ')487 time.sleep(2)488 messages = client.get_messages('@schfratorBot')489 for message in client.get_messages('@schfratorBot', limit=1):490 m = message.message491 self.assertEqual(len(messages), 1)492 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'493 self.assertRegex(m, text)494 client.send_message('@schfratorBot', 'ÑиÑÑ')495 time.sleep(2)496 messages = client.get_messages('@schfratorBot')497 for message in client.get_messages('@schfratorBot', limit=1):498 m = message.message499 self.assertEqual(len(messages), 1)500 text = 'ÐведиÑе ÑекÑÑ:'501 self.assertRegex(m, text)502 client.send_message('@schfratorBot', 'aboba')503 time.sleep(2)504 messages = client.get_messages('@schfratorBot')505 for message in client.get_messages('@schfratorBot', limit=1):506 m = message.message507 self.assertEqual(len(messages), 1)508 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'509 self.assertRegex(m, text)510 client.send_message('@schfratorBot', 'mac')511 time.sleep(2)512 messages = client.get_messages('@schfratorBot')513 for message in client.get_messages('@schfratorBot', limit=1):514 m = message.message515 self.assertEqual(len(messages), 1)516 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'517 self.assertRegex(m, text)518 client.send_message('@schfratorBot', 'Ñамо')519 time.sleep(2)520 messages = client.get_messages('@schfratorBot')521 for message in client.get_messages('@schfratorBot', limit=1):522 m = message.message523 self.assertEqual(len(messages), 1)524 text = 'СделаÑÑ ÑÑÑоÑнÑми?'525 self.assertRegex(m, text)526 client.send_message('@schfratorBot', 'да')527 time.sleep(2)528 messages = client.get_messages('@schfratorBot')529 for message in client.get_messages('@schfratorBot', limit=1):530 m = message.message531 self.assertEqual(len(messages), 1)532 text = 'РезÑлÑÑаÑ:mbqbb'533 self.assertRegex(m, text)534 except:535 self.assertFalse(True)536 def testVisionerRASHengSAMOstr(self):537 try:538 client.send_message('@schfratorBot', '/visioner')539 time.sleep(2)540 messages = client.get_messages('@schfratorBot')541 for message in client.get_messages('@schfratorBot', limit=1):542 m = message.message543 self.assertEqual(len(messages), 1)544 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'545 self.assertRegex(m, text)546 client.send_message('@schfratorBot', 'англ')547 time.sleep(2)548 messages = client.get_messages('@schfratorBot')549 for message in client.get_messages('@schfratorBot', limit=1):550 m = message.message551 self.assertEqual(len(messages), 1)552 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'553 self.assertRegex(m, text)554 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')555 time.sleep(2)556 messages = client.get_messages('@schfratorBot')557 for message in client.get_messages('@schfratorBot', limit=1):558 m = message.message559 self.assertEqual(len(messages), 1)560 text = 'ÐведиÑе ÑекÑÑ:'561 self.assertRegex(m, text)562 client.send_message('@schfratorBot', 'mbqbb')563 time.sleep(2)564 messages = client.get_messages('@schfratorBot')565 for message in client.get_messages('@schfratorBot', limit=1):566 m = message.message567 self.assertEqual(len(messages), 1)568 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'569 self.assertRegex(m, text)570 client.send_message('@schfratorBot', 'macab')571 time.sleep(2)572 messages = client.get_messages('@schfratorBot')573 for message in client.get_messages('@schfratorBot', limit=1):574 m = message.message575 self.assertEqual(len(messages), 1)576 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'577 self.assertRegex(m, text)578 client.send_message('@schfratorBot', 'Ñамо')579 time.sleep(2)580 messages = client.get_messages('@schfratorBot')581 for message in client.get_messages('@schfratorBot', limit=1):582 m = message.message583 self.assertEqual(len(messages), 1)584 text = 'СделаÑÑ ÑÑÑоÑнÑми?'585 self.assertRegex(m, text)586 client.send_message('@schfratorBot', 'да')587 time.sleep(2)588 messages = client.get_messages('@schfratorBot')589 for message in client.get_messages('@schfratorBot', limit=1):590 m = message.message591 self.assertEqual(len(messages), 1)592 text = 'РезÑлÑÑаÑ:aboba'593 self.assertRegex(m, text)594 except:595 self.assertFalse(True)596 def testVisionerSCHrusSAMOstr(self):597 try:598 client.send_message('@schfratorBot', '/visioner')599 time.sleep(2)600 messages = client.get_messages('@schfratorBot')601 for message in client.get_messages('@schfratorBot', limit=1):602 m = message.message603 self.assertEqual(len(messages), 1)604 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'605 self.assertRegex(m, text)606 client.send_message('@schfratorBot', 'ÑÑÑÑ')607 time.sleep(2)608 messages = client.get_messages('@schfratorBot')609 for message in client.get_messages('@schfratorBot', limit=1):610 m = message.message611 self.assertEqual(len(messages), 1)612 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'613 self.assertRegex(m, text)614 client.send_message('@schfratorBot', 'ÑиÑÑ')615 time.sleep(2)616 messages = client.get_messages('@schfratorBot')617 for message in client.get_messages('@schfratorBot', limit=1):618 m = message.message619 self.assertEqual(len(messages), 1)620 text = 'ÐведиÑе ÑекÑÑ:'621 self.assertRegex(m, text)622 client.send_message('@schfratorBot', 'абоба')623 time.sleep(2)624 messages = client.get_messages('@schfratorBot')625 for message in client.get_messages('@schfratorBot', limit=1):626 m = message.message627 self.assertEqual(len(messages), 1)628 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'629 self.assertRegex(m, text)630 client.send_message('@schfratorBot', 'мак')631 time.sleep(2)632 messages = client.get_messages('@schfratorBot')633 for message in client.get_messages('@schfratorBot', limit=1):634 m = message.message635 self.assertEqual(len(messages), 1)636 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'637 self.assertRegex(m, text)638 client.send_message('@schfratorBot', 'ÑамÑ')639 time.sleep(2)640 messages = client.get_messages('@schfratorBot')641 for message in client.get_messages('@schfratorBot', limit=1):642 m = message.message643 self.assertEqual(len(messages), 1)644 text = 'СделаÑÑ ÑÑÑоÑнÑми?'645 self.assertRegex(m, text)646 client.send_message('@schfratorBot', 'да')647 time.sleep(2)648 messages = client.get_messages('@schfratorBot')649 for message in client.get_messages('@schfratorBot', limit=1):650 m = message.message651 self.assertEqual(len(messages), 1)652 text = 'РезÑлÑÑаÑ:мнÑÑÑ'653 self.assertRegex(m, text)654 except:655 self.assertFalse(True)656 def testVisionerRASHrusSAMSHstr(self):657 try:658 client.send_message('@schfratorBot', '/visioner')659 time.sleep(2)660 messages = client.get_messages('@schfratorBot')661 for message in client.get_messages('@schfratorBot', limit=1):662 m = message.message663 self.assertEqual(len(messages), 1)664 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'665 self.assertRegex(m, text)666 client.send_message('@schfratorBot', 'ÑÑÑÑ')667 time.sleep(2)668 messages = client.get_messages('@schfratorBot')669 for message in client.get_messages('@schfratorBot', limit=1):670 m = message.message671 self.assertEqual(len(messages), 1)672 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'673 self.assertRegex(m, text)674 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')675 time.sleep(2)676 messages = client.get_messages('@schfratorBot')677 for message in client.get_messages('@schfratorBot', limit=1):678 m = message.message679 self.assertEqual(len(messages), 1)680 text = 'ÐведиÑе ÑекÑÑ:'681 self.assertRegex(m, text)682 client.send_message('@schfratorBot', 'мнÑÑÑ')683 time.sleep(2)684 messages = client.get_messages('@schfratorBot')685 for message in client.get_messages('@schfratorBot', limit=1):686 m = message.message687 self.assertEqual(len(messages), 1)688 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'689 self.assertRegex(m, text)690 client.send_message('@schfratorBot', 'ммÑÑÑ')691 time.sleep(2)692 messages = client.get_messages('@schfratorBot')693 for message in client.get_messages('@schfratorBot', limit=1):694 m = message.message695 self.assertEqual(len(messages), 1)696 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'697 self.assertRegex(m, text)698 client.send_message('@schfratorBot', 'ÑамÑ')699 time.sleep(2)700 messages = client.get_messages('@schfratorBot')701 for message in client.get_messages('@schfratorBot', limit=1):702 m = message.message703 self.assertEqual(len(messages), 1)704 text = 'СделаÑÑ ÑÑÑоÑнÑми?'705 self.assertRegex(m, text)706 client.send_message('@schfratorBot', 'да')707 time.sleep(2)708 messages = client.get_messages('@schfratorBot')709 for message in client.get_messages('@schfratorBot', limit=1):710 m = message.message711 self.assertEqual(len(messages), 1)712 text = 'РезÑлÑÑаÑ:абоба'713 self.assertRegex(m, text)714 except:715 self.assertFalse(True)716 def testVisionerSCHengSAMSHstr(self):717 try:718 client.send_message('@schfratorBot', '/visioner')719 time.sleep(2)720 messages = client.get_messages('@schfratorBot')721 for message in client.get_messages('@schfratorBot', limit=1):722 m = message.message723 self.assertEqual(len(messages), 1)724 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'725 self.assertRegex(m, text)726 client.send_message('@schfratorBot', 'англ')727 time.sleep(2)728 messages = client.get_messages('@schfratorBot')729 for message in client.get_messages('@schfratorBot', limit=1):730 m = message.message731 self.assertEqual(len(messages), 1)732 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'733 self.assertRegex(m, text)734 client.send_message('@schfratorBot', 'ÑиÑÑ')735 time.sleep(2)736 messages = client.get_messages('@schfratorBot')737 for message in client.get_messages('@schfratorBot', limit=1):738 m = message.message739 self.assertEqual(len(messages), 1)740 text = 'ÐведиÑе ÑекÑÑ:'741 self.assertRegex(m, text)742 client.send_message('@schfratorBot', 'aboba')743 time.sleep(2)744 messages = client.get_messages('@schfratorBot')745 for message in client.get_messages('@schfratorBot', limit=1):746 m = message.message747 self.assertEqual(len(messages), 1)748 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'749 self.assertRegex(m, text)750 client.send_message('@schfratorBot', 'mac')751 time.sleep(2)752 messages = client.get_messages('@schfratorBot')753 for message in client.get_messages('@schfratorBot', limit=1):754 m = message.message755 self.assertEqual(len(messages), 1)756 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'757 self.assertRegex(m, text)758 client.send_message('@schfratorBot', 'ÑамÑ')759 time.sleep(2)760 messages = client.get_messages('@schfratorBot')761 for message in client.get_messages('@schfratorBot', limit=1):762 m = message.message763 self.assertEqual(len(messages), 1)764 text = 'СделаÑÑ ÑÑÑоÑнÑми?'765 self.assertRegex(m, text)766 client.send_message('@schfratorBot', 'да')767 time.sleep(2)768 messages = client.get_messages('@schfratorBot')769 for message in client.get_messages('@schfratorBot', limit=1):770 m = message.message771 self.assertEqual(len(messages), 1)772 text = 'РезÑлÑÑаÑ:mncpp'773 self.assertRegex(m, text)774 except:775 self.assertFalse(True)776 def testVisionerRASHengSAMOstr(self):777 try:778 client.send_message('@schfratorBot', '/visioner')779 time.sleep(2)780 messages = client.get_messages('@schfratorBot')781 for message in client.get_messages('@schfratorBot', limit=1):782 m = message.message783 self.assertEqual(len(messages), 1)784 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'785 self.assertRegex(m, text)786 client.send_message('@schfratorBot', 'англ')787 time.sleep(2)788 messages = client.get_messages('@schfratorBot')789 for message in client.get_messages('@schfratorBot', limit=1):790 m = message.message791 self.assertEqual(len(messages), 1)792 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'793 self.assertRegex(m, text)794 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')795 time.sleep(2)796 messages = client.get_messages('@schfratorBot')797 for message in client.get_messages('@schfratorBot', limit=1):798 m = message.message799 self.assertEqual(len(messages), 1)800 text = 'ÐведиÑе ÑекÑÑ:'801 self.assertRegex(m, text)802 client.send_message('@schfratorBot', 'mncpp')803 time.sleep(2)804 messages = client.get_messages('@schfratorBot')805 for message in client.get_messages('@schfratorBot', limit=1):806 m = message.message807 self.assertEqual(len(messages), 1)808 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'809 self.assertRegex(m, text)810 client.send_message('@schfratorBot', 'mmoop')811 time.sleep(2)812 messages = client.get_messages('@schfratorBot')813 for message in client.get_messages('@schfratorBot', limit=1):814 m = message.message815 self.assertEqual(len(messages), 1)816 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'817 self.assertRegex(m, text)818 client.send_message('@schfratorBot', 'Ñамо')819 time.sleep(2)820 messages = client.get_messages('@schfratorBot')821 for message in client.get_messages('@schfratorBot', limit=1):822 m = message.message823 self.assertEqual(len(messages), 1)824 text = 'СделаÑÑ ÑÑÑоÑнÑми?'825 self.assertRegex(m, text)826 client.send_message('@schfratorBot', 'да')827 time.sleep(2)828 messages = client.get_messages('@schfratorBot')829 for message in client.get_messages('@schfratorBot', limit=1):830 m = message.message831 self.assertEqual(len(messages), 1)832 text = 'РезÑлÑÑаÑ:aboba'833 self.assertRegex(m, text)834 except:835 self.assertFalse(True)836 def testVisionerSCHrusPOVnostr(self):837 try:838 client.send_message('@schfratorBot', '/visioner')839 time.sleep(2)840 messages = client.get_messages('@schfratorBot')841 for message in client.get_messages('@schfratorBot', limit=1):842 m = message.message843 self.assertEqual(len(messages), 1)844 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'845 self.assertRegex(m, text)846 client.send_message('@schfratorBot', 'ÑÑÑÑ')847 time.sleep(2)848 messages = client.get_messages('@schfratorBot')849 for message in client.get_messages('@schfratorBot', limit=1):850 m = message.message851 self.assertEqual(len(messages), 1)852 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'853 self.assertRegex(m, text)854 client.send_message('@schfratorBot', 'ÑиÑÑ')855 time.sleep(2)856 messages = client.get_messages('@schfratorBot')857 for message in client.get_messages('@schfratorBot', limit=1):858 m = message.message859 self.assertEqual(len(messages), 1)860 text = 'ÐведиÑе ÑекÑÑ:'861 self.assertRegex(m, text)862 client.send_message('@schfratorBot', 'абоÐа')863 time.sleep(2)864 messages = client.get_messages('@schfratorBot')865 for message in client.get_messages('@schfratorBot', limit=1):866 m = message.message867 self.assertEqual(len(messages), 1)868 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'869 self.assertRegex(m, text)870 client.send_message('@schfratorBot', 'мак')871 time.sleep(2)872 messages = client.get_messages('@schfratorBot')873 for message in client.get_messages('@schfratorBot', limit=1):874 m = message.message875 self.assertEqual(len(messages), 1)876 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'877 self.assertRegex(m, text)878 client.send_message('@schfratorBot', 'повÑоÑ')879 time.sleep(2)880 messages = client.get_messages('@schfratorBot')881 for message in client.get_messages('@schfratorBot', limit=1):882 m = message.message883 self.assertEqual(len(messages), 1)884 text = 'СделаÑÑ ÑÑÑоÑнÑми?'885 self.assertRegex(m, text)886 client.send_message('@schfratorBot', 'неÑ')887 time.sleep(2)888 messages = client.get_messages('@schfratorBot')889 for message in client.get_messages('@schfratorBot', limit=1):890 m = message.message891 self.assertEqual(len(messages), 1)892 text = 'РезÑлÑÑаÑ:мбÑÐа'893 self.assertRegex(m, text)894 except:895 self.assertFalse(True)896 def testVisionerRASHrusPOVnostr(self):897 try:898 client.send_message('@schfratorBot', '/visioner')899 time.sleep(2)900 messages = client.get_messages('@schfratorBot')901 for message in client.get_messages('@schfratorBot', limit=1):902 m = message.message903 self.assertEqual(len(messages), 1)904 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'905 self.assertRegex(m, text)906 client.send_message('@schfratorBot', 'ÑÑÑÑ')907 time.sleep(2)908 messages = client.get_messages('@schfratorBot')909 for message in client.get_messages('@schfratorBot', limit=1):910 m = message.message911 self.assertEqual(len(messages), 1)912 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'913 self.assertRegex(m, text)914 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')915 time.sleep(2)916 messages = client.get_messages('@schfratorBot')917 for message in client.get_messages('@schfratorBot', limit=1):918 m = message.message919 self.assertEqual(len(messages), 1)920 text = 'ÐведиÑе ÑекÑÑ:'921 self.assertRegex(m, text)922 client.send_message('@schfratorBot', 'мбÑÐа')923 time.sleep(2)924 messages = client.get_messages('@schfratorBot')925 for message in client.get_messages('@schfratorBot', limit=1):926 m = message.message927 self.assertEqual(len(messages), 1)928 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'929 self.assertRegex(m, text)930 client.send_message('@schfratorBot', 'мак')931 time.sleep(2)932 messages = client.get_messages('@schfratorBot')933 for message in client.get_messages('@schfratorBot', limit=1):934 m = message.message935 self.assertEqual(len(messages), 1)936 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'937 self.assertRegex(m, text)938 client.send_message('@schfratorBot', 'повÑоÑ')939 time.sleep(2)940 messages = client.get_messages('@schfratorBot')941 for message in client.get_messages('@schfratorBot', limit=1):942 m = message.message943 self.assertEqual(len(messages), 1)944 text = 'СделаÑÑ ÑÑÑоÑнÑми?'945 self.assertRegex(m, text)946 client.send_message('@schfratorBot', 'да')947 time.sleep(2)948 messages = client.get_messages('@schfratorBot')949 for message in client.get_messages('@schfratorBot', limit=1):950 m = message.message951 self.assertEqual(len(messages), 1)952 text = 'РезÑлÑÑаÑ:абоÐа'953 self.assertRegex(m, text)954 except:955 self.assertFalse(True)956 def testVisionerSCHengPOVnostr(self):957 try:958 client.send_message('@schfratorBot', '/visioner')959 time.sleep(2)960 messages = client.get_messages('@schfratorBot')961 for message in client.get_messages('@schfratorBot', limit=1):962 m = message.message963 self.assertEqual(len(messages), 1)964 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'965 self.assertRegex(m, text)966 client.send_message('@schfratorBot', 'англ')967 time.sleep(2)968 messages = client.get_messages('@schfratorBot')969 for message in client.get_messages('@schfratorBot', limit=1):970 m = message.message971 self.assertEqual(len(messages), 1)972 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'973 self.assertRegex(m, text)974 client.send_message('@schfratorBot', 'ÑиÑÑ')975 time.sleep(2)976 messages = client.get_messages('@schfratorBot')977 for message in client.get_messages('@schfratorBot', limit=1):978 m = message.message979 self.assertEqual(len(messages), 1)980 text = 'ÐведиÑе ÑекÑÑ:'981 self.assertRegex(m, text)982 client.send_message('@schfratorBot', 'aboBa')983 time.sleep(2)984 messages = client.get_messages('@schfratorBot')985 for message in client.get_messages('@schfratorBot', limit=1):986 m = message.message987 self.assertEqual(len(messages), 1)988 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'989 self.assertRegex(m, text)990 client.send_message('@schfratorBot', 'mac')991 time.sleep(2)992 messages = client.get_messages('@schfratorBot')993 for message in client.get_messages('@schfratorBot', limit=1):994 m = message.message995 self.assertEqual(len(messages), 1)996 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'997 self.assertRegex(m, text)998 client.send_message('@schfratorBot', 'повÑоÑ')999 time.sleep(2)1000 messages = client.get_messages('@schfratorBot')1001 for message in client.get_messages('@schfratorBot', limit=1):1002 m = message.message1003 self.assertEqual(len(messages), 1)1004 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1005 self.assertRegex(m, text)1006 client.send_message('@schfratorBot', 'неÑ')1007 time.sleep(2)1008 messages = client.get_messages('@schfratorBot')1009 for message in client.get_messages('@schfratorBot', limit=1):1010 m = message.message1011 self.assertEqual(len(messages), 1)1012 text = 'РезÑлÑÑаÑ:mbqNa'1013 self.assertRegex(m, text)1014 except:1015 self.assertFalse(True)1016 def testVisionerRASHengPOVnostr(self):1017 try:1018 client.send_message('@schfratorBot', '/visioner')1019 time.sleep(2)1020 messages = client.get_messages('@schfratorBot')1021 for message in client.get_messages('@schfratorBot', limit=1):1022 m = message.message1023 self.assertEqual(len(messages), 1)1024 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1025 self.assertRegex(m, text)1026 client.send_message('@schfratorBot', 'англ')1027 time.sleep(2)1028 messages = client.get_messages('@schfratorBot')1029 for message in client.get_messages('@schfratorBot', limit=1):1030 m = message.message1031 self.assertEqual(len(messages), 1)1032 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1033 self.assertRegex(m, text)1034 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')1035 time.sleep(2)1036 messages = client.get_messages('@schfratorBot')1037 for message in client.get_messages('@schfratorBot', limit=1):1038 m = message.message1039 self.assertEqual(len(messages), 1)1040 text = 'ÐведиÑе ÑекÑÑ:'1041 self.assertRegex(m, text)1042 client.send_message('@schfratorBot', 'mbqNa')1043 time.sleep(2)1044 messages = client.get_messages('@schfratorBot')1045 for message in client.get_messages('@schfratorBot', limit=1):1046 m = message.message1047 self.assertEqual(len(messages), 1)1048 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1049 self.assertRegex(m, text)1050 client.send_message('@schfratorBot', 'mac')1051 time.sleep(2)1052 messages = client.get_messages('@schfratorBot')1053 for message in client.get_messages('@schfratorBot', limit=1):1054 m = message.message1055 self.assertEqual(len(messages), 1)1056 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1057 self.assertRegex(m, text)1058 client.send_message('@schfratorBot', 'повÑоÑ')1059 time.sleep(2)1060 messages = client.get_messages('@schfratorBot')1061 for message in client.get_messages('@schfratorBot', limit=1):1062 m = message.message1063 self.assertEqual(len(messages), 1)1064 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1065 self.assertRegex(m, text)1066 client.send_message('@schfratorBot', 'да')1067 time.sleep(2)1068 messages = client.get_messages('@schfratorBot')1069 for message in client.get_messages('@schfratorBot', limit=1):1070 m = message.message1071 self.assertEqual(len(messages), 1)1072 text = 'РезÑлÑÑаÑ:aboBa'1073 self.assertRegex(m, text)1074 except:1075 self.assertFalse(True)1076 def testVisionerSCHrusSAMOnostr(self):1077 try:1078 client.send_message('@schfratorBot', '/visioner')1079 time.sleep(2)1080 messages = client.get_messages('@schfratorBot')1081 for message in client.get_messages('@schfratorBot', limit=1):1082 m = message.message1083 self.assertEqual(len(messages), 1)1084 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1085 self.assertRegex(m, text)1086 client.send_message('@schfratorBot', 'ÑÑÑÑ')1087 time.sleep(2)1088 messages = client.get_messages('@schfratorBot')1089 for message in client.get_messages('@schfratorBot', limit=1):1090 m = message.message1091 self.assertEqual(len(messages), 1)1092 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1093 self.assertRegex(m, text)1094 client.send_message('@schfratorBot', 'ÑиÑÑ')1095 time.sleep(2)1096 messages = client.get_messages('@schfratorBot')1097 for message in client.get_messages('@schfratorBot', limit=1):1098 m = message.message1099 self.assertEqual(len(messages), 1)1100 text = 'ÐведиÑе ÑекÑÑ:'1101 self.assertRegex(m, text)1102 client.send_message('@schfratorBot', 'абоÐа')1103 time.sleep(2)1104 messages = client.get_messages('@schfratorBot')1105 for message in client.get_messages('@schfratorBot', limit=1):1106 m = message.message1107 self.assertEqual(len(messages), 1)1108 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1109 self.assertRegex(m, text)1110 client.send_message('@schfratorBot', 'мак')1111 time.sleep(2)1112 messages = client.get_messages('@schfratorBot')1113 for message in client.get_messages('@schfratorBot', limit=1):1114 m = message.message1115 self.assertEqual(len(messages), 1)1116 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1117 self.assertRegex(m, text)1118 client.send_message('@schfratorBot', 'Ñамо')1119 time.sleep(2)1120 messages = client.get_messages('@schfratorBot')1121 for message in client.get_messages('@schfratorBot', limit=1):1122 m = message.message1123 self.assertEqual(len(messages), 1)1124 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1125 self.assertRegex(m, text)1126 client.send_message('@schfratorBot', 'неÑ')1127 time.sleep(2)1128 messages = client.get_messages('@schfratorBot')1129 for message in client.get_messages('@schfratorBot', limit=1):1130 m = message.message1131 self.assertEqual(len(messages), 1)1132 text = 'РезÑлÑÑаÑ:мбÑÐб'1133 self.assertRegex(m, text)1134 except:1135 self.assertFalse(True)1136 def testVisionerRASHrusSAMOnostr(self):1137 try:1138 client.send_message('@schfratorBot', '/visioner')1139 time.sleep(2)1140 messages = client.get_messages('@schfratorBot')1141 for message in client.get_messages('@schfratorBot', limit=1):1142 m = message.message1143 self.assertEqual(len(messages), 1)1144 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1145 self.assertRegex(m, text)1146 client.send_message('@schfratorBot', 'ÑÑÑÑ')1147 time.sleep(2)1148 messages = client.get_messages('@schfratorBot')1149 for message in client.get_messages('@schfratorBot', limit=1):1150 m = message.message1151 self.assertEqual(len(messages), 1)1152 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1153 self.assertRegex(m, text)1154 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')1155 time.sleep(2)1156 messages = client.get_messages('@schfratorBot')1157 for message in client.get_messages('@schfratorBot', limit=1):1158 m = message.message1159 self.assertEqual(len(messages), 1)1160 text = 'ÐведиÑе ÑекÑÑ:'1161 self.assertRegex(m, text)1162 client.send_message('@schfratorBot', 'мбÑÐб')1163 time.sleep(2)1164 messages = client.get_messages('@schfratorBot')1165 for message in client.get_messages('@schfratorBot', limit=1):1166 m = message.message1167 self.assertEqual(len(messages), 1)1168 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1169 self.assertRegex(m, text)1170 client.send_message('@schfratorBot', 'макаб')1171 time.sleep(2)1172 messages = client.get_messages('@schfratorBot')1173 for message in client.get_messages('@schfratorBot', limit=1):1174 m = message.message1175 self.assertEqual(len(messages), 1)1176 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1177 self.assertRegex(m, text)1178 client.send_message('@schfratorBot', 'Ñамо')1179 time.sleep(2)1180 messages = client.get_messages('@schfratorBot')1181 for message in client.get_messages('@schfratorBot', limit=1):1182 m = message.message1183 self.assertEqual(len(messages), 1)1184 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1185 self.assertRegex(m, text)1186 client.send_message('@schfratorBot', 'неÑ')1187 time.sleep(2)1188 messages = client.get_messages('@schfratorBot')1189 for message in client.get_messages('@schfratorBot', limit=1):1190 m = message.message1191 self.assertEqual(len(messages), 1)1192 text = 'РезÑлÑÑаÑ:абоÐа'1193 self.assertRegex(m, text)1194 except:1195 self.assertFalse(True)1196 def testVisionerSCHengSAMOnostr(self):1197 try:1198 client.send_message('@schfratorBot', '/visioner')1199 time.sleep(2)1200 messages = client.get_messages('@schfratorBot')1201 for message in client.get_messages('@schfratorBot', limit=1):1202 m = message.message1203 self.assertEqual(len(messages), 1)1204 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1205 self.assertRegex(m, text)1206 client.send_message('@schfratorBot', 'англ')1207 time.sleep(2)1208 messages = client.get_messages('@schfratorBot')1209 for message in client.get_messages('@schfratorBot', limit=1):1210 m = message.message1211 self.assertEqual(len(messages), 1)1212 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1213 self.assertRegex(m, text)1214 client.send_message('@schfratorBot', 'ÑиÑÑ')1215 time.sleep(2)1216 messages = client.get_messages('@schfratorBot')1217 for message in client.get_messages('@schfratorBot', limit=1):1218 m = message.message1219 self.assertEqual(len(messages), 1)1220 text = 'ÐведиÑе ÑекÑÑ:'1221 self.assertRegex(m, text)1222 client.send_message('@schfratorBot', 'aboBa')1223 time.sleep(2)1224 messages = client.get_messages('@schfratorBot')1225 for message in client.get_messages('@schfratorBot', limit=1):1226 m = message.message1227 self.assertEqual(len(messages), 1)1228 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1229 self.assertRegex(m, text)1230 client.send_message('@schfratorBot', 'mac')1231 time.sleep(2)1232 messages = client.get_messages('@schfratorBot')1233 for message in client.get_messages('@schfratorBot', limit=1):1234 m = message.message1235 self.assertEqual(len(messages), 1)1236 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1237 self.assertRegex(m, text)1238 client.send_message('@schfratorBot', 'Ñамо')1239 time.sleep(2)1240 messages = client.get_messages('@schfratorBot')1241 for message in client.get_messages('@schfratorBot', limit=1):1242 m = message.message1243 self.assertEqual(len(messages), 1)1244 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1245 self.assertRegex(m, text)1246 client.send_message('@schfratorBot', 'неÑ')1247 time.sleep(2)1248 messages = client.get_messages('@schfratorBot')1249 for message in client.get_messages('@schfratorBot', limit=1):1250 m = message.message1251 self.assertEqual(len(messages), 1)1252 text = 'РезÑлÑÑаÑ:mbqBb'1253 self.assertRegex(m, text)1254 except:1255 self.assertFalse(True)1256 def testVisionerRASHengSAMOnostr(self):1257 try:1258 client.send_message('@schfratorBot', '/visioner')1259 time.sleep(2)1260 messages = client.get_messages('@schfratorBot')1261 for message in client.get_messages('@schfratorBot', limit=1):1262 m = message.message1263 self.assertEqual(len(messages), 1)1264 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1265 self.assertRegex(m, text)1266 client.send_message('@schfratorBot', 'англ')1267 time.sleep(2)1268 messages = client.get_messages('@schfratorBot')1269 for message in client.get_messages('@schfratorBot', limit=1):1270 m = message.message1271 self.assertEqual(len(messages), 1)1272 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1273 self.assertRegex(m, text)1274 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')1275 time.sleep(2)1276 messages = client.get_messages('@schfratorBot')1277 for message in client.get_messages('@schfratorBot', limit=1):1278 m = message.message1279 self.assertEqual(len(messages), 1)1280 text = 'ÐведиÑе ÑекÑÑ:'1281 self.assertRegex(m, text)1282 client.send_message('@schfratorBot', 'mbqBb')1283 time.sleep(2)1284 messages = client.get_messages('@schfratorBot')1285 for message in client.get_messages('@schfratorBot', limit=1):1286 m = message.message1287 self.assertEqual(len(messages), 1)1288 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1289 self.assertRegex(m, text)1290 client.send_message('@schfratorBot', 'macab')1291 time.sleep(2)1292 messages = client.get_messages('@schfratorBot')1293 for message in client.get_messages('@schfratorBot', limit=1):1294 m = message.message1295 self.assertEqual(len(messages), 1)1296 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1297 self.assertRegex(m, text)1298 client.send_message('@schfratorBot', 'Ñамо')1299 time.sleep(2)1300 messages = client.get_messages('@schfratorBot')1301 for message in client.get_messages('@schfratorBot', limit=1):1302 m = message.message1303 self.assertEqual(len(messages), 1)1304 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1305 self.assertRegex(m, text)1306 client.send_message('@schfratorBot', 'неÑ')1307 time.sleep(2)1308 messages = client.get_messages('@schfratorBot')1309 for message in client.get_messages('@schfratorBot', limit=1):1310 m = message.message1311 self.assertEqual(len(messages), 1)1312 text = 'РезÑлÑÑаÑ:aboBa'1313 self.assertRegex(m, text)1314 except:1315 self.assertFalse(True)1316 def testVisionerSCHrusSAMOnostr(self):1317 try:1318 client.send_message('@schfratorBot', '/visioner')1319 time.sleep(2)1320 messages = client.get_messages('@schfratorBot')1321 for message in client.get_messages('@schfratorBot', limit=1):1322 m = message.message1323 self.assertEqual(len(messages), 1)1324 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1325 self.assertRegex(m, text)1326 client.send_message('@schfratorBot', 'ÑÑÑÑ')1327 time.sleep(2)1328 messages = client.get_messages('@schfratorBot')1329 for message in client.get_messages('@schfratorBot', limit=1):1330 m = message.message1331 self.assertEqual(len(messages), 1)1332 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1333 self.assertRegex(m, text)1334 client.send_message('@schfratorBot', 'ÑиÑÑ')1335 time.sleep(2)1336 messages = client.get_messages('@schfratorBot')1337 for message in client.get_messages('@schfratorBot', limit=1):1338 m = message.message1339 self.assertEqual(len(messages), 1)1340 text = 'ÐведиÑе ÑекÑÑ:'1341 self.assertRegex(m, text)1342 client.send_message('@schfratorBot', 'абоÐа')1343 time.sleep(2)1344 messages = client.get_messages('@schfratorBot')1345 for message in client.get_messages('@schfratorBot', limit=1):1346 m = message.message1347 self.assertEqual(len(messages), 1)1348 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1349 self.assertRegex(m, text)1350 client.send_message('@schfratorBot', 'мак')1351 time.sleep(2)1352 messages = client.get_messages('@schfratorBot')1353 for message in client.get_messages('@schfratorBot', limit=1):1354 m = message.message1355 self.assertEqual(len(messages), 1)1356 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1357 self.assertRegex(m, text)1358 client.send_message('@schfratorBot', 'ÑамÑ')1359 time.sleep(2)1360 messages = client.get_messages('@schfratorBot')1361 for message in client.get_messages('@schfratorBot', limit=1):1362 m = message.message1363 self.assertEqual(len(messages), 1)1364 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1365 self.assertRegex(m, text)1366 client.send_message('@schfratorBot', 'неÑ')1367 time.sleep(2)1368 messages = client.get_messages('@schfratorBot')1369 for message in client.get_messages('@schfratorBot', limit=1):1370 m = message.message1371 self.assertEqual(len(messages), 1)1372 text = 'РезÑлÑÑаÑ:мнÑШÑ'1373 self.assertRegex(m, text)1374 except:1375 self.assertFalse(True)1376 def testVisionerRASHrusSAMSHnostr(self):1377 try:1378 client.send_message('@schfratorBot', '/visioner')1379 time.sleep(2)1380 messages = client.get_messages('@schfratorBot')1381 for message in client.get_messages('@schfratorBot', limit=1):1382 m = message.message1383 self.assertEqual(len(messages), 1)1384 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1385 self.assertRegex(m, text)1386 client.send_message('@schfratorBot', 'ÑÑÑÑ')1387 time.sleep(2)1388 messages = client.get_messages('@schfratorBot')1389 for message in client.get_messages('@schfratorBot', limit=1):1390 m = message.message1391 self.assertEqual(len(messages), 1)1392 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1393 self.assertRegex(m, text)1394 client.send_message('@schfratorBot', 'ÑаÑÑиÑÑ')1395 time.sleep(2)1396 messages = client.get_messages('@schfratorBot')1397 for message in client.get_messages('@schfratorBot', limit=1):1398 m = message.message1399 self.assertEqual(len(messages), 1)1400 text = 'ÐведиÑе ÑекÑÑ:'1401 self.assertRegex(m, text)1402 client.send_message('@schfratorBot', 'мнÑШÑ')1403 time.sleep(2)1404 messages = client.get_messages('@schfratorBot')1405 for message in client.get_messages('@schfratorBot', limit=1):1406 m = message.message1407 self.assertEqual(len(messages), 1)1408 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1409 self.assertRegex(m, text)1410 client.send_message('@schfratorBot', 'ммÑÑÑ')1411 time.sleep(2)1412 messages = client.get_messages('@schfratorBot')1413 for message in client.get_messages('@schfratorBot', limit=1):1414 m = message.message1415 self.assertEqual(len(messages), 1)1416 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1417 self.assertRegex(m, text)1418 client.send_message('@schfratorBot', 'ÑамÑ')1419 time.sleep(2)1420 messages = client.get_messages('@schfratorBot')1421 for message in client.get_messages('@schfratorBot', limit=1):1422 m = message.message1423 self.assertEqual(len(messages), 1)1424 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1425 self.assertRegex(m, text)1426 client.send_message('@schfratorBot', 'неÑ')1427 time.sleep(2)1428 messages = client.get_messages('@schfratorBot')1429 for message in client.get_messages('@schfratorBot', limit=1):1430 m = message.message1431 self.assertEqual(len(messages), 1)1432 text = 'РезÑлÑÑаÑ:абоÐа'1433 self.assertRegex(m, text)1434 except:1435 self.assertFalse(True)1436 def testVisionerSCHengSAMSHnostr(self):1437 try:1438 client.send_message('@schfratorBot', '/visioner')1439 time.sleep(2)1440 messages = client.get_messages('@schfratorBot')1441 for message in client.get_messages('@schfratorBot', limit=1):1442 m = message.message1443 self.assertEqual(len(messages), 1)1444 text = 'ÐÑбÑан ÑиÑÑ ÐиженеÑа\n\nЯзÑк ввода - английÑкий, ÑÑÑÑкий\n\nÐÐ¾Ñ Ð¿ÑедоÑÑÐ°Ð²Ð¸Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑ Ð²ÑбоÑа\n\nФÑнкÑии: ÑиÑÑование, ÑаÑÑиÑÑование, вÑÐ±Ð¾Ñ Ð³Ð°Ð¼Ð¼Ñ, пÑиведение к Ð¾Ð´Ð½Ð¾Ð¼Ñ ÑегиÑÑÑÑ\n\nÐÑбеÑиÑе ÑзÑк.ÐÐ»Ñ ÑообÑÐµÐ½Ð¸Ñ Ð½Ð° ÑÑÑÑком ÑзÑке команда - ÑÑÑÑ, а Ð´Ð»Ñ Ð°Ð½Ð³Ð»Ð¸Ð¹Ñкого - англ'1445 self.assertRegex(m, text)1446 client.send_message('@schfratorBot', 'англ')1447 time.sleep(2)1448 messages = client.get_messages('@schfratorBot')1449 for message in client.get_messages('@schfratorBot', limit=1):1450 m = message.message1451 self.assertEqual(len(messages), 1)1452 text = 'ШиÑÑование или ÑаÑÑиÑÑование.ÐÐ¾Ð¼Ð°Ð½Ð´Ñ ÑиÑÑ Ð¸Ð»Ð¸ ÑаÑÑиÑÑ ÑооÑвеÑÑÑвенно?'1453 self.assertRegex(m, text)1454 client.send_message('@schfratorBot', 'ÑиÑÑ')1455 time.sleep(2)1456 messages = client.get_messages('@schfratorBot')1457 for message in client.get_messages('@schfratorBot', limit=1):1458 m = message.message1459 self.assertEqual(len(messages), 1)1460 text = 'ÐведиÑе ÑекÑÑ:'1461 self.assertRegex(m, text)1462 client.send_message('@schfratorBot', 'aboBa')1463 time.sleep(2)1464 messages = client.get_messages('@schfratorBot')1465 for message in client.get_messages('@schfratorBot', limit=1):1466 m = message.message1467 self.assertEqual(len(messages), 1)1468 text = 'ÐведиÑе клÑÑ ÑиÑÑованиÑ:'1469 self.assertRegex(m, text)1470 client.send_message('@schfratorBot', 'mac')1471 time.sleep(2)1472 messages = client.get_messages('@schfratorBot')1473 for message in client.get_messages('@schfratorBot', limit=1):1474 m = message.message1475 self.assertEqual(len(messages), 1)1476 text = 'Ðо какой гамме пÑоизводиÑÑ Ð¾Ð¿ÐµÑаÑии: повÑоÑ,Ñамо,ÑамÑ:'1477 self.assertRegex(m, text)1478 client.send_message('@schfratorBot', 'ÑамÑ')1479 time.sleep(2)1480 messages = client.get_messages('@schfratorBot')1481 for message in client.get_messages('@schfratorBot', limit=1):1482 m = message.message1483 self.assertEqual(len(messages), 1)1484 text = 'СделаÑÑ ÑÑÑоÑнÑми?'1485 self.assertRegex(m, text)1486 client.send_message('@schfratorBot', 'неÑ')1487 time.sleep(2)1488 messages = client.get_messages('@schfratorBot')1489 for message in client.get_messages('@schfratorBot', limit=1):1490 m = message.message1491 self.assertEqual(len(messages), 1)1492 text = 'РезÑлÑÑаÑ:mncPp'1493 self.assertRegex(m, text)1494 except:...
SYSU001.py
Source:SYSU001.py
...30 title, time, address, speaker, person_introduce, content, date = '', '', '', '', '', '', ''31 for message in messages:32 text, replace = self.connect_messages(message.xpath(".//text()").extract())33 if u'é¢ç®ï¼' in replace or 'Titleï¼' in replace or u'é¢ç®:' in replace or 'Title:' in replace:34 title = self.get_messages(text, 'ï¼') if u'é¢ç®ï¼' in replace or 'Titleï¼' in replace else self.get_messages(text, ':')35 elif u'æ¶é´' in replace or 'Timeï¼' in replace or u'æ¶é´:' in replace or 'Time:' in replace:36 time = self.get_messages(text, 'ï¼') if u'æ¶é´ï¼' in replace or 'Timeï¼' in replace else self.get_messages(text, ':')37 elif u'å°ç¹ï¼' in replace or 'Addressï¼' in replace or u'å°ç¹:' in replace or 'Address:' in replace:38 address = self.get_messages(text, 'ï¼') if u'å°ç¹ï¼' in replace or 'Addressï¼' in replace else self.get_messages(text, ':')39 elif u'主讲ï¼' in replace or u'æ¥å人ï¼' in replace or 'Speakerï¼' in replace or u'主讲:' in replace or u'æ¥å人ï¼' in replace or 'Speaker:' in replace:40 speaker = self.get_messages(text, 'ï¼') if u'主讲ï¼' in replace or u'æ¥å人ï¼' in replace or 'Speakerï¼' in replace else self.get_messages(text, ':')41 elif u'æ¥æï¼' in replace or 'Dateï¼' in replace or u'æ¥æ:' in replace or 'Date:' in replace:42 date = self.get_messages(text, 'ï¼') if u'æ¥æï¼' in replace or 'Dateï¼' in replace else self.get_messages(text, ':')43 elif u'å°ç¹ï¼' in text or 'Addressï¼' in replace or u'å°ç¹:' in replace or 'Address:' in replace:44 address = self.get_messages(text, 'ï¼') if u'å°ç¹ï¼' in replace or 'Addressï¼' in replace else self.get_messages(text, ':')45 elif u'ç®ä»ï¼' in text or 'Biographyï¼' in replace or 'Bioï¼' in replace or u'ç®ä»:' in replace or 'Biography:' in replace or 'Bio:' in replace:46 sign = 147 person_introduce = self.get_messages(text, 'ï¼') if u'ç®ä»ï¼' in replace or 'Biographyï¼' in replace or 'Bioï¼' in replace else self.get_messages(text, ':')48 elif u'æè¦ï¼' in replace or 'Abstractï¼' in replace or u'æè¦:' in replace or 'Abstract:' in replace:49 sign = 250 content = self.get_messages(text, 'ï¼') if u'æè¦ï¼' in replace or 'Abstractï¼' in replace else self.get_messages(text, ':')51 else:52 if sign == 1:53 person_introduce += text54 elif sign == 2:55 content += text56 time = (date + ' ' + time).strip()57 if title != '':58 self.counts += 159 print_new_number(self.counts, 'SYSU', self.name)60 all_messages = save_messages('SYSU', self.name, title, time, address, speaker, person_introduce,61 content, '', response.meta['link'], response.meta['number'], u'ä¸å±±å¤§å¦', u'æ°æ®ç§å¦ä¸è®¡ç®æºå¦é¢')62 return all_messages63 def get_messages(self, messages, sign):64 text = ''65 message = messages.split(sign)[1:]66 for i in xrange(len(message)):67 if i > 0:68 text += 'ï¼'69 text += message[i].strip()70 return text71 def connect_messages(self, messages):72 text = ''73 replace = ''74 for message in messages:75 text += message.strip()76 replace += message.strip().replace(' ', '')77 return text, replace
main.py
Source:main.py
...131415@app.route('/message', methods=['GET'])16def messages():17 messages = get_messages()18 return messages192021@socketio.on('message')22def handle_put_message(data):23 res = put_message(data['message'], data['userEmail'])24 emit('get_messages', res, broadcast=True)252627@socketio.on('get_messages')28def handle_get_messages():29 messages = get_messages()30 emit('get_messages', messages)313233@socketio.on('sub_message')34def handle_put_sub_message(message):35 res = put_sub_message(message['message_id'],36 message['message'], message['userEmail'])37 emit('get_messages', res, broadcast=True)383940@socketio.on('update_message')41def handle_update_message(message):42 res = update_message(message['message_id'], message['message'])43 emit('get_messages', res, broadcast=True)
...
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!