mirror of
https://github.com/certbot/certbot.git
synced 2026-07-25 23:29:26 +02:00
Mock time.sleep for more modules to speed up tests (#10427)
The extra 8 seconds isn't really relevant in the test farm, but is nice to have for local runs. This is based on what was done in https://github.com/certbot/certbot/pull/10419/.
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
from unittest import mock
|
||||
|
||||
import pytest
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def mock_sleep():
|
||||
with mock.patch("time.sleep") as mocked:
|
||||
yield mocked
|
||||
@@ -0,0 +1,8 @@
|
||||
from unittest import mock
|
||||
|
||||
import pytest
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def mock_sleep():
|
||||
with mock.patch("time.sleep") as mocked:
|
||||
yield mocked
|
||||
Reference in New Issue
Block a user