def METHOD_NAME(self):
    input = StringIO('input_string')
    prompt = 'some_prompt'
    with mock.patch('sys.stderr') as stderr:
        getpass._raw_input(prompt, input=input)
        stderr.write.assert_called_once_with(prompt)