def METHOD_NAME(self):
    e = self.assertRaises(mitogen.ssh.PasswordError,
        lambda: self.docker_ssh(
            username='mitogen__has_sudo',
        )
    )
    self.assertEqual(e.args[0], mitogen.ssh.password_required_msg)