def setUp(self): self.email_lover = EmailLove() mailgun = MailGun(api_key=os.environ.get('MAILGUN_APIKEY'), domain=os.environ.get('MAILGUN_DOMAIN')) self.email_lover.providers.append(mailgun) self.from_email = os.environ.get('EMAILLOVE_FROM') self.to_email = os.environ.get('EMAILLOVE_TO') if self.to_email is None or self.from_email is None: raise RuntimeError("Please set from/to env variables") self.subject = "EmailLove Mailgun Test"
def setUp(self): self.email_lover = EmailLove() sendgrid = SendGrid(username=os.environ.get('SENDGRID_USER'), password=os.environ.get('SENDGRID_PASS')) self.email_lover.providers.append(sendgrid) self.from_email = os.environ.get('EMAILLOVE_FROM') self.to_email = os.environ.get('EMAILLOVE_TO') if self.to_email is None or self.from_email is None: raise RuntimeError("Please set from/to env variables") self.subject = "EmailLove SendGrid Test"
def setUp(self): self.email_lover = EmailLove() self.test_message = {'subject': 'subject'}