summaryrefslogtreecommitdiffstats
path: root/openshift-storage-libs/openshiftstoragelibs/baseclass.py
diff options
context:
space:
mode:
authorvamahaja <vamahaja@redhat.com>2019-08-13 15:32:12 +0530
committervamahaja <vamahaja@redhat.com>2019-08-13 17:35:30 +0530
commitf0727d7266e0b826aa75f8babdd854bfb268505f (patch)
tree8aef2d1944aea10b02bfb06a40d29fe73fb05c50 /openshift-storage-libs/openshiftstoragelibs/baseclass.py
parentcb815f13c7eab15e89a01e835337a0a5745bf118 (diff)
Reuse more common functions in the GlusterStabilityTestSetup
Change-Id: Ia4e0fb737b16ea7bdc8ffd5ae44cdd418471552a Signed-off-by: vamahaja <vamahaja@redhat.com>
Diffstat (limited to 'openshift-storage-libs/openshiftstoragelibs/baseclass.py')
-rw-r--r--openshift-storage-libs/openshiftstoragelibs/baseclass.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/openshift-storage-libs/openshiftstoragelibs/baseclass.py b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
index 62f2a1f..956cf56 100644
--- a/openshift-storage-libs/openshiftstoragelibs/baseclass.py
+++ b/openshift-storage-libs/openshiftstoragelibs/baseclass.py
@@ -152,6 +152,7 @@ class BaseClass(unittest.TestCase):
def create_storage_class(self, secret_name=None,
sc_name_prefix="autotests-sc",
create_vol_name_prefix=False,
+ vol_name_prefix=None,
allow_volume_expansion=False,
reclaim_policy="Delete",
set_hacount=None,
@@ -183,7 +184,9 @@ class BaseClass(unittest.TestCase):
parameters["volumeoptions"] += (
",user.heketi.average-file-size %s" % (
arbiter_avg_file_size))
- if create_vol_name_prefix:
+ if vol_name_prefix:
+ parameters["volumenameprefix"] = vol_name_prefix
+ elif create_vol_name_prefix:
parameters["volumenameprefix"] = self.sc.get(
"volumenameprefix", "autotest")
self.sc_name = oc_create_sc(