diff options
author | Brian Curtin <brian.curtin@gmail.com> | 2010-11-04 03:41:43 (GMT) |
---|---|---|
committer | Brian Curtin <brian.curtin@gmail.com> | 2010-11-04 03:41:43 (GMT) |
commit | 3beb38f8ffe7b54e3372bc43385e9d5b8de1b6df (patch) | |
tree | 86d8c184e82e58d9d90cbaf0624ff01ab0e06e47 | |
parent | fd15191b9287fc32563c05d460e1ceaa2e60bb0e (diff) | |
download | cpython-3beb38f8ffe7b54e3372bc43385e9d5b8de1b6df.zip cpython-3beb38f8ffe7b54e3372bc43385e9d5b8de1b6df.tar.gz cpython-3beb38f8ffe7b54e3372bc43385e9d5b8de1b6df.tar.bz2 |
Fix three ResourceWarnings.
Mimic the clientTearDown from ThreadedTCPSocketTest, closing the socket.
-rw-r--r-- | Lib/test/test_socket.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_socket.py b/Lib/test/test_socket.py index 704d46e..facb065 100644 --- a/Lib/test/test_socket.py +++ b/Lib/test/test_socket.py @@ -197,6 +197,11 @@ class ThreadedUDPSocketTest(SocketUDPTest, ThreadableTest): def clientSetUp(self): self.cli = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) + def clientTearDown(self): + self.cli.close() + self.cli = None + ThreadableTest.clientTearDown(self) + class SocketConnectedTest(ThreadedTCPSocketTest): """Socket tests for client-server connection. |