Replies: 1 comment 2 replies
-
Yeah, there is an open pr that fixes it |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've noticed that the function
mockImplementation
in spy instances accepts a function that returns a Promise-wrapped value of the original type.mockImplementation(fn: ((...args: TArgs) => TReturns) | (() => Promise<TReturns>)): this
What's the motivation of allowing Promise-wrapped function here? This can possibly lead to invalid mocking, for example:
Related to #3750
Beta Was this translation helpful? Give feedback.
All reactions