diff options
| author | Pranav <prprakas@redhat.com> | 2020-08-04 12:10:02 +0530 | 
|---|---|---|
| committer | Bala Konda Reddy M <bala12352@gmail.com> | 2020-08-06 05:00:00 +0000 | 
| commit | 0b86bc1caa81ca558606d0e68fdf36f3eb5d4a59 (patch) | |
| tree | 98396061fc374d08c8867b15817d04700bbec2c9 /tests | |
| parent | f02807e5540e250ae29c25066fbca5a0a3d239f1 (diff) | |
[TestFix] Fix test test_root_squash_with_volume_restart
Integrate the changes made in library to the test
Change-Id: I9bf8c3f1f732132170a96405a4a12839463a2eaa
Signed-off-by: Pranav <prprakas@redhat.com>
Diffstat (limited to 'tests')
| -rwxr-xr-x[-rw-r--r--] | tests/functional/nfs_ganesha/root-squash/test_root_squash_with_volume_restart.py | 31 | 
1 files changed, 6 insertions, 25 deletions
diff --git a/tests/functional/nfs_ganesha/root-squash/test_root_squash_with_volume_restart.py b/tests/functional/nfs_ganesha/root-squash/test_root_squash_with_volume_restart.py index 7ca02b933..424cda09b 100644..100755 --- a/tests/functional/nfs_ganesha/root-squash/test_root_squash_with_volume_restart.py +++ b/tests/functional/nfs_ganesha/root-squash/test_root_squash_with_volume_restart.py @@ -20,15 +20,14 @@  """  from glusto.core import Glusto as g  from glustolibs.gluster.exceptions import ExecutionError -from glustolibs.gluster.gluster_base_class import runs_on +from glustolibs.gluster.gluster_base_class import runs_on, GlusterBaseClass  from glustolibs.gluster.nfs_ganesha_libs import ( -                NfsGaneshaClusterSetupClass, -                wait_for_nfs_ganesha_volume_to_get_unexported, -                wait_for_nfs_ganesha_volume_to_get_exported) +    wait_for_nfs_ganesha_volume_to_get_unexported, +    wait_for_nfs_ganesha_volume_to_get_exported)  from glustolibs.io.utils import get_mounts_stat  from glustolibs.gluster.nfs_ganesha_ops import ( -                set_root_squash, -                unexport_nfs_ganesha_volume) +    set_root_squash, +    unexport_nfs_ganesha_volume)  from glustolibs.gluster.volume_ops import (volume_stop, volume_start)  from glustolibs.gluster.lib_utils import (append_string_to_file)  from glustolibs.gluster.glusterfile import set_file_permissions @@ -37,20 +36,7 @@ from glustolibs.gluster.glusterfile import set_file_permissions  @runs_on([['replicated', 'distributed', 'distributed-replicated',             'dispersed', 'distributed-dispersed'],            ['nfs']]) -class TestNfsGaneshaRootSquash(NfsGaneshaClusterSetupClass): -    @classmethod -    def setUpClass(cls): -        """ -        Setup nfs-ganesha if not exists. -        """ -        cls.get_super_method(cls, 'setUpClass')() - -        # Setup nfs-ganesha -        ret = cls.setup_nfs_ganesha() -        if not ret: -            raise ExecutionError("Failed to setup nfs-ganesha cluster " -                                 "ganesha cluster") -        g.log.info("nfs-ganesha cluster is healthy") +class TestNfsGaneshaRootSquash(GlusterBaseClass):      def setUp(self):          """ @@ -189,8 +175,3 @@ class TestNfsGaneshaRootSquash(NfsGaneshaClusterSetupClass):              g.log.info("Successful unmount and cleanup of volume")          else:              raise ExecutionError("Failed to unmount and cleanup volume") - -    @classmethod -    def tearDownClass(cls): -        cls.get_super_method(cls, 'tearDownClass')( -            delete_nfs_ganesha_cluster=False)  | 
