diff options
Diffstat (limited to 'tests/functional/snapshot/test_snap_delete_existing_scheduler.py')
-rw-r--r-- | tests/functional/snapshot/test_snap_delete_existing_scheduler.py | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/tests/functional/snapshot/test_snap_delete_existing_scheduler.py b/tests/functional/snapshot/test_snap_delete_existing_scheduler.py index af5d86701..0a29bbfd4 100644 --- a/tests/functional/snapshot/test_snap_delete_existing_scheduler.py +++ b/tests/functional/snapshot/test_snap_delete_existing_scheduler.py @@ -14,8 +14,11 @@ # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +import sys from time import sleep + from glusto.core import Glusto as g + from glustolibs.gluster.exceptions import ExecutionError from glustolibs.gluster.gluster_base_class import GlusterBaseClass, runs_on from glustolibs.misc.misc_libs import upload_scripts @@ -40,7 +43,7 @@ class SnapshotDeleteExistingScheduler(GlusterBaseClass): @classmethod def setUpClass(cls): - 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", cls.clients) @@ -58,7 +61,7 @@ class SnapshotDeleteExistingScheduler(GlusterBaseClass): def setUp(self): # SettingUp volume and Mounting the volume - GlusterBaseClass.setUp.im_func(self) + self.get_super_method(self, 'setUp')() g.log.info("Starting to SetUp and Mount Volume") ret = self.setup_volume_and_mount_volume(mounts=self.mounts) if not ret: @@ -180,9 +183,10 @@ class SnapshotDeleteExistingScheduler(GlusterBaseClass): g.log.info("Starting IO on all mounts...") all_mounts_procs = [] for mount_obj in self.mounts: - cmd = ("python %s create_files " - "-f 10 --base-file-name file %s" % (self.script_upload_path, - mount_obj.mountpoint)) + cmd = ("/usr/bin/env python%d %s create_files " + "-f 10 --base-file-name file %s" % ( + sys.version_info.major, self.script_upload_path, + mount_obj.mountpoint)) proc = g.run_async(mount_obj.client_system, cmd, user=mount_obj.user) all_mounts_procs.append(proc) |