Home | History | Annotate | Download | only in test

Lines Matching refs:asyncore

1 import asyncore
45 raise asyncore.ExitNow()
96 # bubbles all the way up through asyncore read/write/_exception calls
98 self.assertRaises(asyncore.ExitNow, asyncore.read, tr1)
99 self.assertRaises(asyncore.ExitNow, asyncore.write, tr1)
100 self.assertRaises(asyncore.ExitNow, asyncore._exception, tr1)
105 asyncore.read(tr2)
109 asyncore.write(tr2)
113 asyncore._exception(tr2)
116 # asyncore.readwrite uses constants in the select module that
162 asyncore.readwrite(tobj, flag)
170 # bubbles all the way up through asyncore readwrite call
172 self.assertRaises(asyncore.ExitNow, asyncore.readwrite, tr1, flag)
178 asyncore.readwrite(tr2, flag)
199 socketmap = asyncore.socket_map
201 asyncore.socket_map = testmap
202 asyncore.close_all()
204 testmap, asyncore.socket_map = asyncore.socket_map, socketmap
206 asyncore.close_all(testmap)
218 r = asyncore.compact_traceback()
235 asyncore.close_all()
238 d = asyncore.dispatcher()
243 d = asyncore.dispatcher()
244 self.assertEqual(repr(d), '<asyncore.dispatcher at %#x>' % id(d))
247 d = asyncore.dispatcher()
265 d = asyncore.dispatcher()
287 d = asyncore.dispatcher()
314 d = asyncore.dispatcher(socket.socket())
330 err = asyncore._strerror(errno.EPERM)
333 err = asyncore._strerror(-1)
337 class dispatcherwithsend_noread(asyncore.dispatcher_with_send):
351 asyncore.close_all()
384 asyncore.poll()
397 @unittest.skipUnless(hasattr(asyncore, 'file_wrapper'),
398 'asyncore.file_wrapper required')
410 w = asyncore.file_wrapper(fd)
425 w = asyncore.file_wrapper(fd)
433 @unittest.skipUnless(hasattr(asyncore, 'file_dispatcher'),
434 'asyncore.file_dispatcher required')
438 class FileDispatcher(asyncore.file_dispatcher):
443 asyncore.loop(timeout=0.01, use_poll=True, count=2)
447 class BaseTestHandler(asyncore.dispatcher):
450 asyncore.dispatcher.__init__(self, sock)
469 class TCPServer(asyncore.dispatcher):
475 asyncore.dispatcher.__init__(self)
509 asyncore.close_all()
514 while asyncore.socket_map and count > 0:
515 asyncore.loop(timeout=0.01, count=1, use_poll=self.use_poll)
653 asyncore.loop(timeout=0.01, use_poll=self.use_poll, count=100)
672 s = asyncore.dispatcher()
678 s1 = asyncore.dispatcher()
684 s2 = asyncore.dispatcher()
696 # if SO_REUSEADDR succeeded for sock we expect asyncore
698 s = asyncore.dispatcher(socket.socket())
713 t = threading.Thread(target=lambda: asyncore.loop(timeout=0.1, count=500))