Expect a target callable to return a truthy value within the timeout. Args: target: callable that returns truthy if polling condition is met. timeout: max polling time step: interval between checking target()
(
target: Callable[[], T],
timeout: TimeoutType = None,
step: TimeoutType = None,
)
| 779 | |
| 780 | @staticmethod |
| 781 | def expect( |
| 782 | target: Callable[[], T], |
| 783 | timeout: TimeoutType = None, |
| 784 | step: TimeoutType = None, |
| 785 | ): |
| 786 | """Expect a target callable to return a truthy value within the timeout. |
| 787 | |
| 788 | Args: |
| 789 | target: callable that returns truthy if polling condition is met. |
| 790 | timeout: max polling time |
| 791 | step: interval between checking target() |
| 792 | """ |
| 793 | AppHarness.poll_for_or_raise_timeout( |
| 794 | target=target, |
| 795 | timeout=timeout, |
| 796 | step=step, |
| 797 | ) |
| 798 | |
| 799 | |
| 800 | class AppHarnessProd(AppHarness): |
no test coverage detected