PyDocs

Nav

Development Tools

ThreadingMock.wait_until_called

  • ThreadingMock.wait_until_called(*, timeout=UNSET)
Wait until the mock object is called.

`timeout` - time to wait for in seconds, waits forever otherwise.
Defaults to the constructor provided timeout.
Use None to block undefinetively.
1 Example
>>> mock = ThreadingMock()
>>> thread = threading.Thread(target=mock)
>>> thread.start()
>>> mock.wait_until_called(timeout=1)
>>> thread.join()
from the Python docs
See Also
No see-alsos for unittest.mock/ThreadingMock.wait_until_called
0 Notes
No notes for ThreadingMock.wait_until_called