1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2026-03-31 21:17:23 +02:00

rename test modules to not conflict with global package names (e.g. dns)

This commit is contained in:
Joshua Tauberer
2014-04-23 17:43:38 -04:00
parent ccbbc930e2
commit 22ad668699
3 changed files with 0 additions and 0 deletions

19
tests/test_smtp_server.py Executable file
View File

@@ -0,0 +1,19 @@
#!/usr/bin/python3
import smtplib, sys
if len(sys.argv) < 3:
print("Usage: tests/smtp_server.py host email.to email.from")
sys.exit(1)
host, toaddr, fromaddr = sys.argv[1:4]
msg = """From: %s
To: %s
Subject: SMTP server test
This is a test message.""" % (fromaddr, toaddr)
server = smtplib.SMTP(host, 25)
server.set_debuglevel(1)
server.sendmail(fromaddr, [toaddr], msg)
server.quit()