summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
authorRichard Jones <richard@commonground.com.au>2010-08-16 01:48:14 (GMT)
committerRichard Jones <richard@commonground.com.au>2010-08-16 01:48:14 (GMT)
commitdaf235032fc3e0cfbfc279d60c1d12aff8f9b0d2 (patch)
tree846428840ccc67f67a34c014c3792ea54a1818aa /Lib/test
parentb14ac8c2b0eb949b896d5df2831b3e01e06cb7cb (diff)
downloadcpython-daf235032fc3e0cfbfc279d60c1d12aff8f9b0d2.zip
cpython-daf235032fc3e0cfbfc279d60c1d12aff8f9b0d2.tar.gz
cpython-daf235032fc3e0cfbfc279d60c1d12aff8f9b0d2.tar.bz2
close down sockets held by asyncore at end of test; closes issue9619
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/test_smtpd.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_smtpd.py b/Lib/test/test_smtpd.py
index 9d168c7..3d55bb2 100644
--- a/Lib/test/test_smtpd.py
+++ b/Lib/test/test_smtpd.py
@@ -45,6 +45,7 @@ class SMTPDServerTest(TestCase):
self.assertRaises(NotImplementedError, write_line, b'spam\r\n.\r\n')
def tearDown(self):
+ asyncore.close_all()
asyncore.socket = smtpd.socket = socket
@@ -57,6 +58,7 @@ class SMTPDChannelTest(TestCase):
self.channel = smtpd.SMTPChannel(self.server, conn, addr)
def tearDown(self):
+ asyncore.close_all()
asyncore.socket = smtpd.socket = socket
def write_line(self, line):