blob: 012ab9427eb1bb6f697ffd9d940152cafea1a3d4 [file] [log] [blame]
Guido van Rossum806c2462007-08-06 23:33:07 +00001import asyncore
Guido van Rossum04110fb2007-08-24 16:32:05 +00002import email.utils
Guido van Rossumd8faa362007-04-27 19:54:29 +00003import socket
4import threading
Guido van Rossum806c2462007-08-06 23:33:07 +00005import smtpd
Guido van Rossumd8faa362007-04-27 19:54:29 +00006import smtplib
Guido van Rossum806c2462007-08-06 23:33:07 +00007import io
8import sys
Guido van Rossumd8faa362007-04-27 19:54:29 +00009import time
Guido van Rossum806c2462007-08-06 23:33:07 +000010import select
Guido van Rossumd8faa362007-04-27 19:54:29 +000011
12from unittest import TestCase
Benjamin Petersonee8712c2008-05-20 21:35:26 +000013from test import support
Guido van Rossumd8faa362007-04-27 19:54:29 +000014
Benjamin Petersonee8712c2008-05-20 21:35:26 +000015HOST = support.HOST
Guido van Rossumd8faa362007-04-27 19:54:29 +000016
Josiah Carlsond74900e2008-07-07 04:15:08 +000017if sys.platform == 'darwin':
18 # select.poll returns a select.POLLHUP at the end of the tests
19 # on darwin, so just ignore it
20 def handle_expt(self):
21 pass
22 smtpd.SMTPChannel.handle_expt = handle_expt
23
24
Christian Heimes5e696852008-04-09 08:37:03 +000025def server(evt, buf, serv):
Christian Heimes380f7f22008-02-28 11:19:05 +000026 serv.listen(5)
27 evt.set()
Guido van Rossumd8faa362007-04-27 19:54:29 +000028 try:
29 conn, addr = serv.accept()
30 except socket.timeout:
31 pass
32 else:
Guido van Rossum806c2462007-08-06 23:33:07 +000033 n = 500
34 while buf and n > 0:
35 r, w, e = select.select([], [conn], [])
36 if w:
37 sent = conn.send(buf)
38 buf = buf[sent:]
39
40 n -= 1
Guido van Rossum806c2462007-08-06 23:33:07 +000041
Guido van Rossumd8faa362007-04-27 19:54:29 +000042 conn.close()
43 finally:
44 serv.close()
45 evt.set()
46
47class GeneralTests(TestCase):
48
49 def setUp(self):
50 self.evt = threading.Event()
Christian Heimes5e696852008-04-09 08:37:03 +000051 self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
52 self.sock.settimeout(15)
Benjamin Petersonee8712c2008-05-20 21:35:26 +000053 self.port = support.bind_port(self.sock)
Christian Heimes5e696852008-04-09 08:37:03 +000054 servargs = (self.evt, b"220 Hola mundo\n", self.sock)
Guido van Rossum806c2462007-08-06 23:33:07 +000055 threading.Thread(target=server, args=servargs).start()
Christian Heimes380f7f22008-02-28 11:19:05 +000056 self.evt.wait()
57 self.evt.clear()
Guido van Rossumd8faa362007-04-27 19:54:29 +000058
59 def tearDown(self):
60 self.evt.wait()
61
Guido van Rossum806c2462007-08-06 23:33:07 +000062 def testBasic1(self):
Guido van Rossumd8faa362007-04-27 19:54:29 +000063 # connects
Christian Heimes5e696852008-04-09 08:37:03 +000064 smtp = smtplib.SMTP(HOST, self.port)
Georg Brandlf78e02b2008-06-10 17:40:04 +000065 smtp.close()
Guido van Rossumd8faa362007-04-27 19:54:29 +000066
Guido van Rossum806c2462007-08-06 23:33:07 +000067 def testBasic2(self):
68 # connects, include port in host name
Christian Heimes5e696852008-04-09 08:37:03 +000069 smtp = smtplib.SMTP("%s:%s" % (HOST, self.port))
Georg Brandlf78e02b2008-06-10 17:40:04 +000070 smtp.close()
Guido van Rossum806c2462007-08-06 23:33:07 +000071
72 def testLocalHostName(self):
73 # check that supplied local_hostname is used
Christian Heimes5e696852008-04-09 08:37:03 +000074 smtp = smtplib.SMTP(HOST, self.port, local_hostname="testhost")
Guido van Rossum806c2462007-08-06 23:33:07 +000075 self.assertEqual(smtp.local_hostname, "testhost")
Georg Brandlf78e02b2008-06-10 17:40:04 +000076 smtp.close()
Guido van Rossum806c2462007-08-06 23:33:07 +000077
Guido van Rossumd8faa362007-04-27 19:54:29 +000078 def testTimeoutDefault(self):
Georg Brandlf78e02b2008-06-10 17:40:04 +000079 self.assertTrue(socket.getdefaulttimeout() is None)
80 socket.setdefaulttimeout(30)
81 try:
82 smtp = smtplib.SMTP(HOST, self.port)
83 finally:
84 socket.setdefaulttimeout(None)
Guido van Rossumd8faa362007-04-27 19:54:29 +000085 self.assertEqual(smtp.sock.gettimeout(), 30)
Georg Brandlf78e02b2008-06-10 17:40:04 +000086 smtp.close()
Guido van Rossumd8faa362007-04-27 19:54:29 +000087
88 def testTimeoutNone(self):
Georg Brandlf78e02b2008-06-10 17:40:04 +000089 self.assertTrue(socket.getdefaulttimeout() is None)
Guido van Rossumd8faa362007-04-27 19:54:29 +000090 socket.setdefaulttimeout(30)
91 try:
Christian Heimes5e696852008-04-09 08:37:03 +000092 smtp = smtplib.SMTP(HOST, self.port, timeout=None)
Guido van Rossumd8faa362007-04-27 19:54:29 +000093 finally:
Georg Brandlf78e02b2008-06-10 17:40:04 +000094 socket.setdefaulttimeout(None)
95 self.assertTrue(smtp.sock.gettimeout() is None)
96 smtp.close()
97
98 def testTimeoutValue(self):
99 smtp = smtplib.SMTP(HOST, self.port, timeout=30)
Guido van Rossumd8faa362007-04-27 19:54:29 +0000100 self.assertEqual(smtp.sock.gettimeout(), 30)
Georg Brandlf78e02b2008-06-10 17:40:04 +0000101 smtp.close()
Guido van Rossumd8faa362007-04-27 19:54:29 +0000102
103
Guido van Rossum04110fb2007-08-24 16:32:05 +0000104# Test server thread using the specified SMTP server class
Christian Heimes5e696852008-04-09 08:37:03 +0000105def debugging_server(serv, serv_evt, client_evt):
Christian Heimes380f7f22008-02-28 11:19:05 +0000106 serv_evt.set()
Guido van Rossum806c2462007-08-06 23:33:07 +0000107
108 try:
109 if hasattr(select, 'poll'):
110 poll_fun = asyncore.poll2
111 else:
112 poll_fun = asyncore.poll
113
114 n = 1000
115 while asyncore.socket_map and n > 0:
116 poll_fun(0.01, asyncore.socket_map)
117
118 # when the client conversation is finished, it will
119 # set client_evt, and it's then ok to kill the server
Benjamin Peterson672b8032008-06-11 19:14:14 +0000120 if client_evt.is_set():
Guido van Rossum806c2462007-08-06 23:33:07 +0000121 serv.close()
122 break
123
124 n -= 1
125
126 except socket.timeout:
127 pass
128 finally:
Benjamin Peterson672b8032008-06-11 19:14:14 +0000129 if not client_evt.is_set():
Christian Heimes380f7f22008-02-28 11:19:05 +0000130 # allow some time for the client to read the result
131 time.sleep(0.5)
132 serv.close()
Guido van Rossum806c2462007-08-06 23:33:07 +0000133 asyncore.close_all()
Guido van Rossum806c2462007-08-06 23:33:07 +0000134 serv_evt.set()
135
136MSG_BEGIN = '---------- MESSAGE FOLLOWS ----------\n'
137MSG_END = '------------ END MESSAGE ------------\n'
138
Guido van Rossum04110fb2007-08-24 16:32:05 +0000139# NOTE: Some SMTP objects in the tests below are created with a non-default
140# local_hostname argument to the constructor, since (on some systems) the FQDN
141# lookup caused by the default local_hostname sometimes takes so long that the
Guido van Rossum806c2462007-08-06 23:33:07 +0000142# test server times out, causing the test to fail.
Guido van Rossum04110fb2007-08-24 16:32:05 +0000143
144# Test behavior of smtpd.DebuggingServer
Guido van Rossum806c2462007-08-06 23:33:07 +0000145class DebuggingServerTests(TestCase):
146
147 def setUp(self):
148 # temporarily replace sys.stdout to capture DebuggingServer output
149 self.old_stdout = sys.stdout
150 self.output = io.StringIO()
151 sys.stdout = self.output
152
153 self.serv_evt = threading.Event()
154 self.client_evt = threading.Event()
Benjamin Petersonee8712c2008-05-20 21:35:26 +0000155 self.port = support.find_unused_port()
Christian Heimes5e696852008-04-09 08:37:03 +0000156 self.serv = smtpd.DebuggingServer((HOST, self.port), ('nowhere', -1))
157 serv_args = (self.serv, self.serv_evt, self.client_evt)
Guido van Rossum806c2462007-08-06 23:33:07 +0000158 threading.Thread(target=debugging_server, args=serv_args).start()
159
160 # wait until server thread has assigned a port number
Christian Heimes380f7f22008-02-28 11:19:05 +0000161 self.serv_evt.wait()
162 self.serv_evt.clear()
Guido van Rossum806c2462007-08-06 23:33:07 +0000163
164 def tearDown(self):
165 # indicate that the client is finished
166 self.client_evt.set()
167 # wait for the server thread to terminate
168 self.serv_evt.wait()
169 # restore sys.stdout
170 sys.stdout = self.old_stdout
171
172 def testBasic(self):
173 # connect
Christian Heimes5e696852008-04-09 08:37:03 +0000174 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum806c2462007-08-06 23:33:07 +0000175 smtp.quit()
176
Guido van Rossum04110fb2007-08-24 16:32:05 +0000177 def testNOOP(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000178 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000179 expected = (250, b'Ok')
180 self.assertEqual(smtp.noop(), expected)
181 smtp.quit()
182
183 def testRSET(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000184 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000185 expected = (250, b'Ok')
186 self.assertEqual(smtp.rset(), expected)
187 smtp.quit()
188
189 def testNotImplemented(self):
190 # EHLO isn't implemented in DebuggingServer
Christian Heimes5e696852008-04-09 08:37:03 +0000191 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum806c2462007-08-06 23:33:07 +0000192 expected = (502, b'Error: command "EHLO" not implemented')
193 self.assertEqual(smtp.ehlo(), expected)
194 smtp.quit()
195
Guido van Rossum04110fb2007-08-24 16:32:05 +0000196 def testVRFY(self):
197 # VRFY isn't implemented in DebuggingServer
Christian Heimes5e696852008-04-09 08:37:03 +0000198 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000199 expected = (502, b'Error: command "VRFY" not implemented')
200 self.assertEqual(smtp.vrfy('nobody@nowhere.com'), expected)
201 self.assertEqual(smtp.verify('nobody@nowhere.com'), expected)
202 smtp.quit()
203
204 def testSecondHELO(self):
205 # check that a second HELO returns a message that it's a duplicate
206 # (this behavior is specific to smtpd.SMTPChannel)
Christian Heimes5e696852008-04-09 08:37:03 +0000207 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000208 smtp.helo()
209 expected = (503, b'Duplicate HELO/EHLO')
210 self.assertEqual(smtp.helo(), expected)
211 smtp.quit()
212
Guido van Rossum806c2462007-08-06 23:33:07 +0000213 def testHELP(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000214 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum806c2462007-08-06 23:33:07 +0000215 self.assertEqual(smtp.help(), b'Error: command "HELP" not implemented')
216 smtp.quit()
217
218 def testSend(self):
219 # connect and send mail
220 m = 'A test message'
Christian Heimes5e696852008-04-09 08:37:03 +0000221 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=3)
Guido van Rossum806c2462007-08-06 23:33:07 +0000222 smtp.sendmail('John', 'Sally', m)
Neal Norwitz25329672008-08-25 03:55:03 +0000223 # XXX(nnorwitz): this test is flaky and dies with a bad file descriptor
224 # in asyncore. This sleep might help, but should really be fixed
225 # properly by using an Event variable.
226 time.sleep(0.01)
Guido van Rossum806c2462007-08-06 23:33:07 +0000227 smtp.quit()
228
229 self.client_evt.set()
230 self.serv_evt.wait()
231 self.output.flush()
232 mexpect = '%s%s\n%s' % (MSG_BEGIN, m, MSG_END)
233 self.assertEqual(self.output.getvalue(), mexpect)
234
235
Christian Heimes380f7f22008-02-28 11:19:05 +0000236class NonConnectingTests(TestCase):
237
238 def testNotConnected(self):
239 # Test various operations on an unconnected SMTP object that
240 # should raise exceptions (at present the attempt in SMTP.send
241 # to reference the nonexistent 'sock' attribute of the SMTP object
242 # causes an AttributeError)
243 smtp = smtplib.SMTP()
244 self.assertRaises(smtplib.SMTPServerDisconnected, smtp.ehlo)
245 self.assertRaises(smtplib.SMTPServerDisconnected,
246 smtp.send, 'test msg')
247
248 def testNonnumericPort(self):
249 # check that non-numeric port raises socket.error
250 self.assertRaises(socket.error, smtplib.SMTP,
251 "localhost", "bogus")
252 self.assertRaises(socket.error, smtplib.SMTP,
253 "localhost:bogus")
254
255
Guido van Rossum04110fb2007-08-24 16:32:05 +0000256# test response of client to a non-successful HELO message
Guido van Rossum806c2462007-08-06 23:33:07 +0000257class BadHELOServerTests(TestCase):
258
259 def setUp(self):
260 self.old_stdout = sys.stdout
261 self.output = io.StringIO()
262 sys.stdout = self.output
263
264 self.evt = threading.Event()
Christian Heimes5e696852008-04-09 08:37:03 +0000265 self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
266 self.sock.settimeout(15)
Benjamin Petersonee8712c2008-05-20 21:35:26 +0000267 self.port = support.bind_port(self.sock)
Christian Heimes5e696852008-04-09 08:37:03 +0000268 servargs = (self.evt, b"199 no hello for you!\n", self.sock)
Guido van Rossum806c2462007-08-06 23:33:07 +0000269 threading.Thread(target=server, args=servargs).start()
Christian Heimes380f7f22008-02-28 11:19:05 +0000270 self.evt.wait()
271 self.evt.clear()
Guido van Rossum806c2462007-08-06 23:33:07 +0000272
273 def tearDown(self):
274 self.evt.wait()
275 sys.stdout = self.old_stdout
276
277 def testFailingHELO(self):
278 self.assertRaises(smtplib.SMTPConnectError, smtplib.SMTP,
Christian Heimes5e696852008-04-09 08:37:03 +0000279 HOST, self.port, 'localhost', 3)
Guido van Rossumd8faa362007-04-27 19:54:29 +0000280
Guido van Rossum04110fb2007-08-24 16:32:05 +0000281
282sim_users = {'Mr.A@somewhere.com':'John A',
283 'Ms.B@somewhere.com':'Sally B',
284 'Mrs.C@somewhereesle.com':'Ruth C',
285 }
286
R. David Murraycaa27b72009-05-23 18:49:56 +0000287sim_auth = ('Mr.A@somewhere.com', 'somepassword')
288sim_auth_b64encoded = 'AE1yLkFAc29tZXdoZXJlLmNvbQBzb21lcGFzc3dvcmQ='
289
Guido van Rossum04110fb2007-08-24 16:32:05 +0000290sim_lists = {'list-1':['Mr.A@somewhere.com','Mrs.C@somewhereesle.com'],
291 'list-2':['Ms.B@somewhere.com',],
292 }
293
294# Simulated SMTP channel & server
295class SimSMTPChannel(smtpd.SMTPChannel):
296 def smtp_EHLO(self, arg):
297 resp = '250-testhost\r\n' \
298 '250-EXPN\r\n' \
299 '250-SIZE 20000000\r\n' \
300 '250-STARTTLS\r\n' \
301 '250-DELIVERBY\r\n' \
R. David Murraycaa27b72009-05-23 18:49:56 +0000302 '250-AUTH PLAIN\r\n' \
Guido van Rossum04110fb2007-08-24 16:32:05 +0000303 '250 HELP'
304 self.push(resp)
305
306 def smtp_VRFY(self, arg):
307# print '\nsmtp_VRFY(%r)\n' % arg
308
309 raw_addr = email.utils.parseaddr(arg)[1]
310 quoted_addr = smtplib.quoteaddr(arg)
311 if raw_addr in sim_users:
312 self.push('250 %s %s' % (sim_users[raw_addr], quoted_addr))
313 else:
314 self.push('550 No such user: %s' % arg)
315
316 def smtp_EXPN(self, arg):
317# print '\nsmtp_EXPN(%r)\n' % arg
318
319 list_name = email.utils.parseaddr(arg)[1].lower()
320 if list_name in sim_lists:
321 user_list = sim_lists[list_name]
322 for n, user_email in enumerate(user_list):
323 quoted_addr = smtplib.quoteaddr(user_email)
324 if n < len(user_list) - 1:
325 self.push('250-%s %s' % (sim_users[user_email], quoted_addr))
326 else:
327 self.push('250 %s %s' % (sim_users[user_email], quoted_addr))
328 else:
329 self.push('550 No access for you!')
330
R. David Murraycaa27b72009-05-23 18:49:56 +0000331 def smtp_AUTH(self, arg):
332 mech, auth = arg.split()
333 if mech.lower() == 'plain':
334 if auth == sim_auth_b64encoded:
335 self.push('235 ok, go ahead')
336 else:
337 self.push('550 No access for you!')
338 else:
339 self.push('504 auth type unimplemented')
340
Guido van Rossum04110fb2007-08-24 16:32:05 +0000341
342class SimSMTPServer(smtpd.SMTPServer):
343 def handle_accept(self):
344 conn, addr = self.accept()
345 channel = SimSMTPChannel(self, conn, addr)
346
347 def process_message(self, peer, mailfrom, rcpttos, data):
348 pass
349
350
351# Test various SMTP & ESMTP commands/behaviors that require a simulated server
352# (i.e., something with more features than DebuggingServer)
353class SMTPSimTests(TestCase):
354
355 def setUp(self):
356 self.serv_evt = threading.Event()
357 self.client_evt = threading.Event()
Benjamin Petersonee8712c2008-05-20 21:35:26 +0000358 self.port = support.find_unused_port()
Christian Heimes5e696852008-04-09 08:37:03 +0000359 self.serv = SimSMTPServer((HOST, self.port), ('nowhere', -1))
360 serv_args = (self.serv, self.serv_evt, self.client_evt)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000361 threading.Thread(target=debugging_server, args=serv_args).start()
362
363 # wait until server thread has assigned a port number
Christian Heimes380f7f22008-02-28 11:19:05 +0000364 self.serv_evt.wait()
365 self.serv_evt.clear()
Guido van Rossum04110fb2007-08-24 16:32:05 +0000366
367 def tearDown(self):
368 # indicate that the client is finished
369 self.client_evt.set()
370 # wait for the server thread to terminate
371 self.serv_evt.wait()
372
373 def testBasic(self):
374 # smoke test
Christian Heimes5e696852008-04-09 08:37:03 +0000375 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=15)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000376 smtp.quit()
377
378 def testEHLO(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000379 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=15)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000380
381 # no features should be present before the EHLO
382 self.assertEqual(smtp.esmtp_features, {})
383
384 # features expected from the test server
385 expected_features = {'expn':'',
386 'size': '20000000',
387 'starttls': '',
388 'deliverby': '',
R. David Murraycaa27b72009-05-23 18:49:56 +0000389 'auth': ' PLAIN',
Guido van Rossum04110fb2007-08-24 16:32:05 +0000390 'help': '',
391 }
392
393 smtp.ehlo()
394 self.assertEqual(smtp.esmtp_features, expected_features)
395 for k in expected_features:
396 self.assertTrue(smtp.has_extn(k))
397 self.assertFalse(smtp.has_extn('unsupported-feature'))
398 smtp.quit()
399
400 def testVRFY(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000401 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=15)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000402
403 for email, name in sim_users.items():
404 expected_known = (250, bytes('%s %s' %
Guido van Rossum5a23cc52007-08-30 14:02:43 +0000405 (name, smtplib.quoteaddr(email)),
406 "ascii"))
Guido van Rossum04110fb2007-08-24 16:32:05 +0000407 self.assertEqual(smtp.vrfy(email), expected_known)
408
409 u = 'nobody@nowhere.com'
Thomas Wouters74e68c72007-08-31 00:20:14 +0000410 expected_unknown = (550, ('No such user: %s'
411 % smtplib.quoteaddr(u)).encode('ascii'))
Guido van Rossum04110fb2007-08-24 16:32:05 +0000412 self.assertEqual(smtp.vrfy(u), expected_unknown)
413 smtp.quit()
414
415 def testEXPN(self):
Christian Heimes5e696852008-04-09 08:37:03 +0000416 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=15)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000417
418 for listname, members in sim_lists.items():
419 users = []
420 for m in members:
421 users.append('%s %s' % (sim_users[m], smtplib.quoteaddr(m)))
Guido van Rossum5a23cc52007-08-30 14:02:43 +0000422 expected_known = (250, bytes('\n'.join(users), "ascii"))
Guido van Rossum04110fb2007-08-24 16:32:05 +0000423 self.assertEqual(smtp.expn(listname), expected_known)
424
425 u = 'PSU-Members-List'
426 expected_unknown = (550, b'No access for you!')
427 self.assertEqual(smtp.expn(u), expected_unknown)
428 smtp.quit()
429
R. David Murraycaa27b72009-05-23 18:49:56 +0000430 def testAUTH(self):
431 smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost', timeout=15)
432
433 expected_auth_ok = (235, b'ok, go ahead')
434 self.assertEqual(smtp.login(sim_auth[0], sim_auth[1]), expected_auth_ok)
Guido van Rossum04110fb2007-08-24 16:32:05 +0000435
436
Guido van Rossumd8faa362007-04-27 19:54:29 +0000437def test_main(verbose=None):
Benjamin Petersonee8712c2008-05-20 21:35:26 +0000438 support.run_unittest(GeneralTests, DebuggingServerTests,
Christian Heimes380f7f22008-02-28 11:19:05 +0000439 NonConnectingTests,
Guido van Rossum04110fb2007-08-24 16:32:05 +0000440 BadHELOServerTests, SMTPSimTests)
Guido van Rossumd8faa362007-04-27 19:54:29 +0000441
442if __name__ == '__main__':
443 test_main()