summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvamahaja <vamahaja@redhat.com>2020-03-24 21:00:35 +0530
committervamahaja <vamahaja@redhat.com>2020-03-25 10:41:17 +0530
commitc697befe2b21543186b24b1092b79ddcd6a60273 (patch)
tree6742dcfaf6348a8aef1145a9b9bfbf14f0b7192a
parentba1b7160be31a55be8299df72b531037393cc6b9 (diff)
[LibFix] Fix PVC create/status library timeouts
Change-Id: I8e027ff71429cd73eea892c6e27d53f638badc42 Signed-off-by: vamahaja <vamahaja@redhat.com>
-rw-r--r--openshift-storage-libs/openshiftstoragelibs/baseclass.py7
-rw-r--r--openshift-storage-libs/openshiftstoragelibs/openshift_ops.py4
2 files changed, 6 insertions, 5 deletions
diff --git a/openshift-storage-libs/openshiftstoragelibs/baseclass.py b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
index 7a7b425..738b5c9 100644
--- a/openshift-storage-libs/openshiftstoragelibs/baseclass.py
+++ b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
@@ -321,7 +321,7 @@ class BaseClass(unittest.TestCase):
def create_and_wait_for_pvcs(
self, pvc_size=1, pvc_name_prefix="autotests-pvc", pvc_amount=1,
- sc_name=None, timeout=120, wait_step=3, skip_waiting=False,
+ sc_name=None, timeout=600, wait_step=10, skip_waiting=False,
skip_cleanup=False):
"""Create multiple PVC's not waiting for it
@@ -400,10 +400,11 @@ class BaseClass(unittest.TestCase):
def create_and_wait_for_pvc(
self, pvc_size=1, pvc_name_prefix='autotests-pvc', sc_name=None,
- skip_cleanup=False):
+ timeout=300, wait_step=10, skip_cleanup=False):
self.pvc_name = self.create_and_wait_for_pvcs(
pvc_size=pvc_size, pvc_name_prefix=pvc_name_prefix,
- sc_name=sc_name, skip_cleanup=skip_cleanup)[0]
+ sc_name=sc_name, timeout=timeout, wait_step=wait_step,
+ skip_cleanup=skip_cleanup)[0]
return self.pvc_name
def create_pvcs_not_waiting(
diff --git a/openshift-storage-libs/openshiftstoragelibs/openshift_ops.py b/openshift-storage-libs/openshiftstoragelibs/openshift_ops.py
index aaf384d..531e9d9 100644
--- a/openshift-storage-libs/openshiftstoragelibs/openshift_ops.py
+++ b/openshift-storage-libs/openshiftstoragelibs/openshift_ops.py
@@ -1183,7 +1183,7 @@ def get_pvc_status(hostname, pvc_name):
return output
-def wait_for_pvcs_be_bound(hostname, pvc_names, timeout=120, wait_step=3):
+def wait_for_pvcs_be_bound(hostname, pvc_names, timeout=300, wait_step=10):
"""Wait for bunch of PVCs to be in 'Bound' state.
Args:
@@ -1246,7 +1246,7 @@ def wait_for_pvcs_be_bound(hostname, pvc_names, timeout=120, wait_step=3):
raise exceptions.ExecutionError(error_msg)
-def wait_for_pvc_be_bound(hostname, pvc_name, timeout=120, wait_step=3):
+def wait_for_pvc_be_bound(hostname, pvc_name, timeout=300, wait_step=10):
return wait_for_pvcs_be_bound(
hostname, pvc_name, timeout=timeout, wait_step=wait_step)