I did try that, giving __name__ and __doc__ to the Mock, the issue was attaching __module__ -- I couldn't get that to work.

Using `@wraps` isn't essential, all you're getting out of it is a slightly nicer presentation of the wrapped function, so this could be dropped.