在 python 中 如何对坚韧库重试进行单元测试

In python How to unit test a tenacity library retry

提问人:joepitz1 提问时间:11/8/2023 更新时间:11/8/2023 访问量:17

问:

我有一个具有韧性库重试的函数

@retry(stop=stop_after_attempt(3))
def func():
    pass

如何对重试执行 3 次进行单元测试? 谢谢

单元测试 python-unittest 重试逻辑 坚韧

评论


答: 暂无答案