Speed up tests by 30 seconds
The retry test for CTS doesn't actually need to wait. Let's mock the sleep function. Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
parent
147df93f75
commit
df6664098d
@ -812,6 +812,7 @@ class TracebackTest(unittest.TestCase):
|
|||||||
|
|
||||||
|
|
||||||
class RetryRequestTest(unittest.TestCase):
|
class RetryRequestTest(unittest.TestCase):
|
||||||
|
@mock.patch("time.sleep", new=lambda x: x)
|
||||||
@mock.patch("pungi.compose.requests")
|
@mock.patch("pungi.compose.requests")
|
||||||
def test_retry_timeout(self, mocked_requests):
|
def test_retry_timeout(self, mocked_requests):
|
||||||
mocked_requests.post.side_effect = [
|
mocked_requests.post.side_effect = [
|
||||||
|
Loading…
Reference in New Issue
Block a user