diff options
author | Valerii Ponomarov <vponomar@redhat.com> | 2019-12-13 20:05:55 +0530 |
---|---|---|
committer | Bala Konda Reddy M <bmekala@redhat.com> | 2019-12-18 10:38:52 +0000 |
commit | 902dc78766d0938f0e40c71c25a4ce2bb10b005d (patch) | |
tree | bbb34f4fc5cdd9b2494d89d589d51bc5a4cfa604 /tests/functional/glusterd/test_create_vol_with_used_bricks.py | |
parent | 065f51e673b3ccc39b153423359bed2dd572935d (diff) |
[py2to3] Add py3 support in 'tests/functional/glusterd'. Part 1
Change-Id: Ib414b8496ca65a48bbe42936e32a863c9c1072e4
Signed-off-by: Valerii Ponomarov <kiparis.kh@gmail.com>
Diffstat (limited to 'tests/functional/glusterd/test_create_vol_with_used_bricks.py')
-rw-r--r-- | tests/functional/glusterd/test_create_vol_with_used_bricks.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/functional/glusterd/test_create_vol_with_used_bricks.py b/tests/functional/glusterd/test_create_vol_with_used_bricks.py index e37741d56..62b08a0c7 100644 --- a/tests/functional/glusterd/test_create_vol_with_used_bricks.py +++ b/tests/functional/glusterd/test_create_vol_with_used_bricks.py @@ -18,7 +18,10 @@ Create volume using bricks of deleted volume """ +import sys + 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.gluster.brick_ops import add_brick @@ -37,7 +40,7 @@ class TestCreateVolWithUsedBricks(GlusterBaseClass): @classmethod def setUpClass(cls): cls.counter = 1 - GlusterBaseClass.setUpClass.im_func(cls) + cls.get_super_method(cls, 'setUpClass')() # Uploading file_dir script in all client direcotries g.log.info("Upload io scripts to clients %s for running IO on " @@ -78,7 +81,7 @@ class TestCreateVolWithUsedBricks(GlusterBaseClass): "dir's of deleted volume") # Calling GlusterBaseClass tearDown - GlusterBaseClass.tearDown.im_func(self) + self.get_super_method(self, 'tearDown')() def test_create_vol_used_bricks(self): ''' @@ -120,12 +123,13 @@ class TestCreateVolWithUsedBricks(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 5 " "--max-num-of-dirs 3 " - "--num-of-files 10 %s" % (self.script_upload_path, + "--num-of-files 10 %s" % (sys.version_info.major, + self.script_upload_path, self.counter, mount_obj.mountpoint)) |