示例#1
0
 def test_acc_and_alias(self):
     # send to acc-and-alias
     token = mail.send(to=['acc-and-alias@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
示例#2
0
 def test_send_to_alias_with_mulitple_destinations(self):
     token = mail.send(to=['alias2@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
示例#3
0
 def test_catchall(self):
     token = mail.send(to=['does-not-exist@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
示例#4
0
 def test_basic_alias(self):
     # send mail to existing alias, should also still work
     token = mail.send(to=['alias1@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
示例#5
0
 def test_basic_account(self):
     # send mail directly to account, should still work
     token = mail.send(to=['acc1@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
示例#6
0
 def test_alias_to_external(self):
     token = mail.send(to=['alias4@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     for ext in CONFIG['external']:
         mail.waitformail(
             token=token,
             server=ext['mailbox_server'],
             port=ext['mailbox_port'],
             user=ext['username'],
             password=ext['password'],
             debug=CONFIG['debug'],
             ssl=True,
         )
示例#7
0
 def test_send_indirect_double_via_alias(self):
     token = mail.send(to=['alias3@' + CONFIG['test_domain']],
                       from_addr='acc1@' + CONFIG['test_domain'],
                       server=CONFIG['submission_server'],
                       port='587',
                       user='******' + CONFIG['test_domain'],
                       password=PASS,
                       debug=CONFIG['debug'],
                       ssl=True)
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )
     mail.waitformail(
         token=token,
         server=CONFIG['mailbox_server'],
         port="993",
         user='******' + CONFIG['test_domain'],
         password=PASS,
         debug=CONFIG['debug'],
         ssl=True,
     )