summaryrefslogtreecommitdiffstats
path: root/tests/functional/disperse/test_ec_fops_brickdown.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/functional/disperse/test_ec_fops_brickdown.py')
-rw-r--r--tests/functional/disperse/test_ec_fops_brickdown.py26
1 files changed, 15 insertions, 11 deletions
diff --git a/tests/functional/disperse/test_ec_fops_brickdown.py b/tests/functional/disperse/test_ec_fops_brickdown.py
index 111523253..f7cac1fcf 100644
--- a/tests/functional/disperse/test_ec_fops_brickdown.py
+++ b/tests/functional/disperse/test_ec_fops_brickdown.py
@@ -19,7 +19,11 @@ Test Description:
Tests File Operations on an EC volume when redundant bricks are
brought down
"""
+
+import sys
+
from glusto.core import Glusto as g
+
from glustolibs.gluster.gluster_base_class import (GlusterBaseClass, runs_on)
from glustolibs.gluster.exceptions import ExecutionError
from glustolibs.misc.misc_libs import upload_scripts
@@ -40,7 +44,7 @@ class TestFopsBrickdown(GlusterBaseClass):
@classmethod
def setUpClass(cls):
# Calling GlusterBaseClass setUpClass
- GlusterBaseClass.setUpClass.im_func(cls)
+ cls.get_super_method(cls, 'setUpClass')()
# Upload io scripts for running IO on mounts
g.log.info("Upload io scripts to clients %s for running IO on mounts",
@@ -56,7 +60,7 @@ class TestFopsBrickdown(GlusterBaseClass):
def setUp(self):
# Calling GlusterBaseClass setUp
- GlusterBaseClass.setUp.im_func(self)
+ self.get_super_method(self, 'setUp')()
# Setup Volume and Mount Volume
g.log.info("Starting to Setup Volume and Mount Volume")
@@ -81,7 +85,7 @@ class TestFopsBrickdown(GlusterBaseClass):
g.log.info("Successful in umounting the volume and Cleanup")
# Calling GlusterBaseClass teardown
- GlusterBaseClass.tearDown.im_func(self)
+ self.get_super_method(self, 'tearDown')()
def test_fops_ec_brickdown(self):
# pylint: disable=too-many-branches,too-many-statements,too-many-locals
@@ -261,14 +265,14 @@ class TestFopsBrickdown(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 10 "
"--max-num-of-dirs 5 "
- "--num-of-files 5 %s/dir1" % (self.script_upload_path,
- count,
- mount_obj.mountpoint))
+ "--num-of-files 5 %s/dir1" % (
+ sys.version_info.major, self.script_upload_path, count,
+ mount_obj.mountpoint))
proc = g.run_async(mount_obj.client_system, cmd,
user=mount_obj.user)
all_mounts_procs.append(proc)
@@ -300,14 +304,14 @@ class TestFopsBrickdown(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 10 "
"--max-num-of-dirs 5 "
- "--num-of-files 5 %s/dir2" % (self.script_upload_path,
- count,
- mount_obj.mountpoint))
+ "--num-of-files 5 %s/dir2" % (
+ sys.version_info.major, self.script_upload_path, count,
+ mount_obj.mountpoint))
proc = g.run_async(mount_obj.client_system, cmd,
user=mount_obj.user)
all_mounts_procs.append(proc)