diff options
author | Charles-François Natali <neologix@free.fr> | 2011-11-10 19:33:36 (GMT) |
---|---|---|
committer | Charles-François Natali <neologix@free.fr> | 2011-11-10 19:33:36 (GMT) |
commit | 240c55f721aee364f7fc341f86c5a25ab5c97095 (patch) | |
tree | ccbdd13bc5f4ffd562dfb26dc8431fbca14b1012 /Lib/test/test_socket.py | |
parent | 24729f36bfb935e14fa53ab9459a4d1ac4da15fe (diff) | |
download | cpython-240c55f721aee364f7fc341f86c5a25ab5c97095.zip cpython-240c55f721aee364f7fc341f86c5a25ab5c97095.tar.gz cpython-240c55f721aee364f7fc341f86c5a25ab5c97095.tar.bz2 |
Fix test_socket when built whithout threads.
Diffstat (limited to 'Lib/test/test_socket.py')
-rw-r--r-- | Lib/test/test_socket.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/test/test_socket.py b/Lib/test/test_socket.py index b5e0dc2..7aef8e9 100644 --- a/Lib/test/test_socket.py +++ b/Lib/test/test_socket.py @@ -305,7 +305,6 @@ class ThreadedRDSSocketTest(SocketRDSTest, ThreadableTest): def __init__(self, methodName='runTest'): SocketRDSTest.__init__(self, methodName=methodName) ThreadableTest.__init__(self) - self.evt = threading.Event() def clientSetUp(self): self.cli = socket.socket(socket.PF_RDS, socket.SOCK_SEQPACKET, 0) @@ -1316,6 +1315,10 @@ class RDSTest(ThreadedRDSSocketTest): def __init__(self, methodName='runTest'): ThreadedRDSSocketTest.__init__(self, methodName=methodName) + def setUp(self): + super().setUp() + self.evt = threading.Event() + def testSendAndRecv(self): data, addr = self.serv.recvfrom(self.bufsize) self.assertEqual(self.data, data) |