Improve variance around worker timing test
This commit is contained in:
parent
f93b6eec63
commit
f70c00dd4c
@ -111,7 +111,7 @@ def test_throttle_sleep_time(mocker, default_conf, caplog) -> None:
|
|||||||
timeframe_offset=0.4, x=5) == 42
|
timeframe_offset=0.4, x=5) == 42
|
||||||
assert sleep_mock.call_count == 1
|
assert sleep_mock.call_count == 1
|
||||||
# 300 (5m) - 60 (1m - see set time above) - 5 (duration of throttled_func) = 235
|
# 300 (5m) - 60 (1m - see set time above) - 5 (duration of throttled_func) = 235
|
||||||
assert 235 < sleep_mock.call_args[0][0] < 235.4
|
assert 235.2 < sleep_mock.call_args[0][0] < 235.6
|
||||||
|
|
||||||
|
|
||||||
def test_throttle_with_assets(mocker, default_conf) -> None:
|
def test_throttle_with_assets(mocker, default_conf) -> None:
|
||||||
|
Loading…
Reference in New Issue
Block a user