Is your feature request related to a problem? Please describe.
In integration/system test scenarios, it is almost always the case that the polling target will be interacted with in an asynchronous manner; but in other more specific/local examples, it could be that a sync interaction is needed. Currently, this is somewhat supported by wrapping the sync operation in a Task.FromResult, but it would be nice if this was supported by default.
Describe the solution you'd like
Create a sync overload for the Poll.Target so that also synchronous interactions are more clean when polling a target.
Is your feature request related to a problem? Please describe. In integration/system test scenarios, it is almost always the case that the polling target will be interacted with in an asynchronous manner; but in other more specific/local examples, it could be that a sync interaction is needed. Currently, this is somewhat supported by wrapping the sync operation in a
Task.FromResult
, but it would be nice if this was supported by default.Describe the solution you'd like Create a sync overload for the
Poll.Target
so that also synchronous interactions are more clean when polling a target.