MCPcopy
hub / github.com/django/django / test_lazy_addresses

Method test_lazy_addresses

tests/mail/tests.py:2012–2020  ·  view source on GitHub ↗

Email sending should support lazy email addresses (#24416).

(self)

Source from the content-addressed store, hash-verified

2010 self.assertEqual(message.get("to"), "to@xn--4ca9at.com")
2011
2012 def test_lazy_addresses(self):
2013 """
2014 Email sending should support lazy email addresses (#24416).
2015 """
2016 _ = gettext_lazy
2017 send_mail("Subject", "Content", _("tester"), [_("django")])
2018 message = self.get_outbox_message()
2019 self.assertEqual(message.get("from"), "tester")
2020 self.assertEqual(message.get("to"), "django")
2021
2022 # RemovedInDjango70Warning.
2023 def test_connection_arg(self):

Callers

nothing calls this directly

Calls 3

send_mailFunction · 0.90
get_outbox_messageMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected