We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3d13efc commit 9c530bbCopy full SHA for 9c530bb
tests/test_backoff.py
@@ -11,8 +11,8 @@ def test_exponential_with_jitter_backoff(monkeypatch: pytest.MonkeyPatch) -> Non
11
12
bo = ExponentialWithJitterBackoff(cap=5, base=1)
13
14
- assert bo.compute(0) == 0.25 # min(5, 0.25*2^0)
15
- assert bo.compute(1) == 1.0 # min(5, 0.5*2^1)
16
- assert bo.compute(2) == 3.0 # min(5, 0.75*2^2)
17
- assert bo.compute(3) == 5.0 # min(5, 1*2^3)
18
- assert bo.compute(4) == 5.0 # min(5, 0.9*2^4)
+ assert bo.compute(0) == 0.25 # min(5, 0.25*2^0)
+ assert bo.compute(1) == 1.0 # min(5, 0.5*2^1)
+ assert bo.compute(2) == 3.0 # min(5, 0.75*2^2)
+ assert bo.compute(3) == 5.0 # min(5, 1*2^3)
+ assert bo.compute(4) == 5.0 # min(5, 0.9*2^4)
0 commit comments