def test_get_for_save_adds_from(self): InputMail.FROM_EMAIL_ADDRESS = "*****@*****.**" headers = {"Subject": "The subject", "Date": str(datetime.now()), "To": "*****@*****.**"} input_mail = InputMail() input_mail.headers = headers self.assertEqual("*****@*****.**", input_mail.get_for_save(1, "SENT")[1][HEADERS_KEY]["From"])
def test_get_for_save_adds_from(self): InputMail.FROM_EMAIL_ADDRESS = '*****@*****.**' headers = {'Subject': 'The subject', 'Date': str(datetime.now()), 'To': '*****@*****.**'} input_mail = InputMail() input_mail.headers = headers self.assertEqual('*****@*****.**', input_mail.get_for_save(1, 'SENT')[1][fields.HEADERS_KEY]['From'])