Commit e4499a88 authored by Giampaolo Rodolà's avatar Giampaolo Rodolà

adds handle_error(self):raise to test modules using asyncore to provide a...

adds handle_error(self):raise to test modules using asyncore to provide a clearer error message in case something goes wrong
parent 215b6b39
......@@ -48,6 +48,9 @@ class DummyDTPHandler(asynchat.async_chat):
self.close()
self.dtp_conn_closed = True
def handle_error(self):
raise
class DummyFTPHandler(asynchat.async_chat):
......
......@@ -366,6 +366,9 @@ class SimSMTPChannel(smtpd.SMTPChannel):
else:
self.push('550 No access for you!')
def handle_error(self):
raise
class SimSMTPServer(smtpd.SMTPServer):
......@@ -384,6 +387,9 @@ class SimSMTPServer(smtpd.SMTPServer):
def add_feature(self, feature):
self._extra_features.append(feature)
def handle_error(self):
raise
# Test various SMTP & ESMTP commands/behaviors that require a simulated server
# (i.e., something with more features than DebuggingServer)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment