SIGN IN SIGN UP

gh-84753: Make inspect.iscoroutinefunction() work with AsyncMock (GH-94050) (GH-94461)

The inspect version was not working with unittest.mock.AsyncMock.

The fix introduces special-casing of AsyncMock in
`inspect.iscoroutinefunction` equivalent to the one
performed in `asyncio.iscoroutinefunction`.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 4261b6bffc0b8bb5c6d4d80578a81b7520f4aefc)

Co-authored-by: Mehdi ABAAKOUK <sileht@sileht.net>
M
Miss Islington (bot) committed
47f23b2d8a14a2f182375c840776eadfc371c726
Parent: d915ed2
Committed by GitHub <noreply@github.com> on 6/30/2022, 6:02:15 PM