Conversation
|
I think this implementation is good, I am wondering if @tirkarthi's suggestion of: wouldn't be better, as it might cover more use cases. It might have the potential of helping out with the backwards compatibility issue with 3.6 in testing-cabal/mock#476. What do you think Karthikeyan? |
|
@czardoz - please can you add a NEWS entry for this? |
|
I would prefer accessing function from |
|
@czardoz - can you add a NEWS entry for this please, I'd like to merge it :-) |
|
Wrong way round, closing this in favour of #18116. |
|
@tirkarthi - I think I'm fine with the |

Essentially, patching a coroutinefunction decorated with
@classmethodor@staticmethoddoes not currently work correctly. Instead of creating anAsyncMock(),patch()uses aMock(), which fails when it's awaited on.https://bugs.python.org/issue39082