summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_smtpd.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2010-07-29 13:19:42 (GMT)
committerGeorg Brandl <georg@python.org>2010-07-29 13:19:42 (GMT)
commit6d23c44ee513058ba272a0d6ad2066252684799c (patch)
tree165d146cf7e62b1a81da6be4363fb868229c5459 /Lib/test/test_smtpd.py
parent8dcaa7396fd89ec84a29ae90c7958d0618ee6c62 (diff)
downloadcpython-6d23c44ee513058ba272a0d6ad2066252684799c.zip
cpython-6d23c44ee513058ba272a0d6ad2066252684799c.tar.gz
cpython-6d23c44ee513058ba272a0d6ad2066252684799c.tar.bz2
Fix #9412: make list of messages an instance attribute instead of class attribute.
Diffstat (limited to 'Lib/test/test_smtpd.py')
-rw-r--r--Lib/test/test_smtpd.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/test/test_smtpd.py b/Lib/test/test_smtpd.py
index 2d62239..538525b 100644
--- a/Lib/test/test_smtpd.py
+++ b/Lib/test/test_smtpd.py
@@ -42,7 +42,9 @@ class DummySocket:
pass
class DummyServer(smtpd.SMTPServer):
- messages = []
+ def __init__(self, *args):
+ smtpd.SMTPServer.__init__(self, *args)
+ self.messages = []
def create_socket(self, family, type):
self.family_and_type = (socket.AF_INET, socket.SOCK_STREAM)
self.set_socket(DummySocket())