'L{twisted.mail.smtp.sendmail} passes through the sender domain name, if
provided.'

def test_senderDomainName(self):

    reactor = MemoryReactor()
    smtp.sendmail('localhost', 'source@address', 'recipient@address', 'message', reactor=reactor, senderDomainName='foo')
    factory = reactor.tcpClients[0][2]
    self.assertEqual(factory.domain, 'foo')
