summaryrefslogtreecommitdiffstats
path: root/openshift-storage-libs/openshiftstoragelibs/baseclass.py
diff options
context:
space:
mode:
authorValerii Ponomarov <vponomar@redhat.com>2019-09-20 20:22:29 +0530
committervponomar <vponomar@redhat.com>2019-09-23 15:06:38 +0000
commitf8b96b793f087bbbcde8a875ad52fe401a76c84a (patch)
tree26570b810c17ebfbc7ed293d4b897bc578d929cb /openshift-storage-libs/openshiftstoragelibs/baseclass.py
parent8b1408de6738d83147925788f66bb8145eaf823f (diff)
Add multiple PVCs states waiter
Add new function called 'wait_for_pvcs_be_bound', which allows us to wait for 'Bound' state of multiple PVCs using single timeout. Also, reuse this new function in the baseclass.py Change-Id: Ia3809d322925b90fdef984db59b3e9e83a82abc7
Diffstat (limited to 'openshift-storage-libs/openshiftstoragelibs/baseclass.py')
-rw-r--r--openshift-storage-libs/openshiftstoragelibs/baseclass.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/openshift-storage-libs/openshiftstoragelibs/baseclass.py b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
index 156aee86..69985f6b 100644
--- a/openshift-storage-libs/openshiftstoragelibs/baseclass.py
+++ b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
@@ -34,7 +34,7 @@ from openshiftstoragelibs.openshift_ops import (
oc_get_pods,
scale_dcs_pod_amount_and_wait,
switch_oc_project,
- verify_pvc_status_is_bound,
+ wait_for_pvcs_be_bound,
wait_for_resources_absence,
)
from openshiftstoragelibs.openshift_storage_libs import (
@@ -250,8 +250,7 @@ class BaseClass(unittest.TestCase):
# Wait for PVCs to be in bound state
try:
- for pvc_name in pvc_names:
- verify_pvc_status_is_bound(node, pvc_name, timeout, wait_step)
+ wait_for_pvcs_be_bound(node, pvc_names, timeout, wait_step)
finally:
if get_openshift_version() < "3.9":
reclaim_policy = "Delete"