From acbf42f89d966eceecaabcaad639afbd8d65696f Mon Sep 17 00:00:00 2001 From: Martin Zimmermann Date: Sun, 27 Oct 2013 12:47:48 +0100 Subject: [PATCH] fix SMTP connectivity test, appendum to a8d0670 --- isso/notify.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/isso/notify.py b/isso/notify.py index c37c30f..adb5244 100644 --- a/isso/notify.py +++ b/isso/notify.py @@ -58,6 +58,10 @@ class SMTPMailer(object): self.from_addr = conf.get('SMTP', 'from') self.to_addr = conf.get('SMTP', 'to') + # test SMTP connectivity + with Connection(self.conf): + pass + def sendmail(self, subject, body): msg = MIMEText(body, 'plain', 'utf-8')