2.0.0a3
Pre-release-
Added first-class async/await stubbing support: async callables now preserve
awaitable behavior forthenReturn,thenRaise, andthenAnswer(including
sync and async answer callables), with parity acrosswhen,when2,
patch, andexpect.
Note that async introspection metadata (e.g.inspect.iscoroutinefunction)
for stub wrappers is currently implemented only on Python 3.12+. -
Added first-class property/descriptor stubbing support, including class-level property
stubbing viawhen(F).p.thenReturn(...)andthenCallOriginalImplementation()support for
property stubs (including chained answers like
thenReturn(...).thenCallOriginalImplementation()). Stubbing instance properties now fails
fast with clear guidance to use class-level stubbing (when(F).p...).