summaryrefslogtreecommitdiffstats
path: root/tests/functional/arbiter/brick_cases/test_brickcases.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/functional/arbiter/brick_cases/test_brickcases.py')
-rwxr-xr-xtests/functional/arbiter/brick_cases/test_brickcases.py27
1 files changed, 15 insertions, 12 deletions
diff --git a/tests/functional/arbiter/brick_cases/test_brickcases.py b/tests/functional/arbiter/brick_cases/test_brickcases.py
index ec5ac0a0e..51f89714c 100755
--- a/tests/functional/arbiter/brick_cases/test_brickcases.py
+++ b/tests/functional/arbiter/brick_cases/test_brickcases.py
@@ -16,7 +16,10 @@
""" Test Arbiter Specific Cases"""
+import sys
+
from glusto.core import Glusto as g
+
from glustolibs.gluster.gluster_base_class import (GlusterBaseClass, runs_on)
from glustolibs.gluster.volume_libs import (
log_volume_info_and_status, replace_brick_from_volume,
@@ -41,7 +44,7 @@ class GlusterArbiterVolumeTypeChangeClass(GlusterBaseClass):
@classmethod
def setUpClass(cls):
# Calling GlusterBaseClass setUpClass
- GlusterBaseClass.setUpClass.im_func(cls)
+ cls.get_super_method(cls, 'setUpClass')()
# Overriding the volume type to specifically test the volume type
# change from replicated to arbiter
@@ -91,8 +94,8 @@ class GlusterArbiterVolumeTypeChangeClass(GlusterBaseClass):
"""
- Setup Volume and Mount Volume
"""
- # Calling GlusterBaseClass setUpClass
- GlusterBaseClass.setUpClass.im_func(self)
+ # Calling GlusterBaseClass setUp
+ self.get_super_method(self, 'setUp')()
self.all_mounts_procs = []
self.io_validation_complete = False
@@ -135,7 +138,7 @@ class GlusterArbiterVolumeTypeChangeClass(GlusterBaseClass):
g.log.info("Successful in Unmount Volume and Cleanup Volume")
# Calling GlusterBaseClass tearDown
- GlusterBaseClass.tearDown.im_func(self)
+ self.get_super_method(self, 'tearDown')()
def test_replicated_to_arbiter_volume_change_with_volume_ops(self):
"""
@@ -152,14 +155,14 @@ class GlusterArbiterVolumeTypeChangeClass(GlusterBaseClass):
for mount_obj in self.mounts:
g.log.info("Starting IO on %s:%s", mount_obj.client_system,
mount_obj.mountpoint)
- cmd = ("python %s create_deep_dirs_with_files "
+ cmd = ("/usr/bin/env python%d %s create_deep_dirs_with_files "
"--dirname-start-num %d "
"--dir-depth 2 "
"--dir-length 15 "
"--max-num-of-dirs 5 "
- "--num-of-files 5 %s" % (self.script_upload_path,
- self.counter,
- mount_obj.mountpoint))
+ "--num-of-files 5 %s" % (
+ sys.version_info.major, self.script_upload_path,
+ self.counter, mount_obj.mountpoint))
proc = g.run_async(mount_obj.client_system, cmd,
user=mount_obj.user)
self.all_mounts_procs.append(proc)
@@ -221,14 +224,14 @@ class GlusterArbiterVolumeTypeChangeClass(GlusterBaseClass):
for mount_obj in self.mounts:
g.log.info("Starting IO on %s:%s", mount_obj.client_system,
mount_obj.mountpoint)
- cmd = ("python %s create_deep_dirs_with_files "
+ cmd = ("/usr/bin/env python%d %s create_deep_dirs_with_files "
"--dirname-start-num %d "
"--dir-depth 2 "
"--dir-length 35 "
"--max-num-of-dirs 5 "
- "--num-of-files 5 %s" % (self.script_upload_path,
- self.counter,
- mount_obj.mountpoint))
+ "--num-of-files 5 %s" % (
+ sys.version_info.major, self.script_upload_path,
+ self.counter, mount_obj.mountpoint))
proc = g.run_async(mount_obj.client_system, cmd,
user=mount_obj.user)
self.all_mounts_procs.append(proc)