'Test mirror dummy user creation for sender when sending to stream'

@mock.patch('DNS.dnslookup', return_value=[['sipbtest:*:20922:101:Fred    Sipb,,,:/mit/sipbtest:/bin/athena/tcsh']])
def test_zephyr_mirror_new_sender(self, ignored):

    client = get_client(name='zephyr_mirror')
    user = self.mit_user('starnine')
    sender_email = 'new_sender@mit.edu'
    recipients = ['stream_name']
    Request = namedtuple('Request', ['POST', 'client'])
    request = Request(POST=dict(sender=sender_email, type='stream'), client=client)
    (valid_input, mirror_sender) = create_mirrored_message_users(request, user, recipients)
    assert (mirror_sender is not None)
    self.assertTrue(valid_input)
    self.assertEqual(mirror_sender.email, sender_email)
    self.assertTrue(mirror_sender.is_mirror_dummy)
