From dda21fc619518344dfc44081c64674f6374fe404 Mon Sep 17 00:00:00 2001 From: Barry Warsaw Date: Sat, 5 Jul 2008 10:41:12 -0400 Subject: Implement the basic Mail-Archive.com archiving algorithm. Fix the start up of the SMTPServer to listen on a consistent port number. post_number -> post_id --- mailman/testing/helpers.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'mailman/testing/helpers.py') diff --git a/mailman/testing/helpers.py b/mailman/testing/helpers.py index af687828f..706ef603f 100644 --- a/mailman/testing/helpers.py +++ b/mailman/testing/helpers.py @@ -162,7 +162,7 @@ class SMTPServer: """An smtp server for testing.""" host = 'localhost' - port = 9025 + port = 10825 def __init__(self): self._messages = [] @@ -174,6 +174,10 @@ class SMTPServer: """Start the smtp server in a thread.""" log.info('test SMTP server starting') self._thread.start() + smtpd = smtplib.SMTP() + smtpd.connect(self.host, self.port) + smtpd.helo('test.localhost') + smtpd.quit() def stop(self): """Stop the smtp server.""" -- cgit v1.2.3-70-g09d2