tenacity
tenacity copied to clipboard
Cannot easily mock out async sleep function
Issue #228 pointed out that it was difficult to patch the sleep function in tests. It was then fixed and now mocking time.sleep is straightforward.
Could the same be done for the async version AsyncRetrying? It would be nice if it was equally easy to mock asyncio.sleep.