You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
expect_oneshot_request and expect_request are responsible for similar actions, but expect_oneshot_request takes one optional keyword argument more (ordered). I propose to:
The optional keyword argument could be type or something like that, as ordered=HandlerType.ONESHOT does not look good, as having a oneshot rule is orthogonal to whether it is ordered or not.
But this is just about the naming. :)
This change is not backward compatible!
1. Define enum `HandlerType`.
2. Make `expect_request` universal so that it could register permanent,
oneshot, and ordered handlers by adding enum `HandlerType` argument with
default value `HandlerType.PERMANENT`.
3. Remove ordered argument from expect_oneshot_request.
4. Add convenience method expect_ordered_request.
Fixes#9.
expect_oneshot_request
andexpect_request
are responsible for similar actions, butexpect_oneshot_request
takes one optional keyword argument more (ordered
). I propose to:HandlerType
:expect_request
universal so that it could register permanent, oneshot, and ordered handlers by adding optional enumHandlerType
argument.ordered
argument fromexpect_oneshot_request
.expect_ordered_request
.The text was updated successfully, but these errors were encountered: