From: Varsha Rao Date: Fri, 19 Jun 2020 09:00:22 +0000 (+0530) Subject: qa/tasks/cephfs/nfs: Poll for max 60 seconds to ensure removal of ganesha services X-Git-Tag: v15.2.5~166^2~28 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ddd604a9251a7f557c88607e9bc70f363bc7c05a;p=ceph.git qa/tasks/cephfs/nfs: Poll for max 60 seconds to ensure removal of ganesha services Fixes: https://tracker.ceph.com/issues/46104 Signed-off-by: Varsha Rao (cherry picked from commit 0caa54bae89dc3f3f47348129c1bc137b44a6a4d) --- diff --git a/qa/tasks/cephfs/test_nfs.py b/qa/tasks/cephfs/test_nfs.py index 850b0b736ef..a2ce2382f82 100644 --- a/qa/tasks/cephfs/test_nfs.py +++ b/qa/tasks/cephfs/test_nfs.py @@ -64,9 +64,15 @@ class TestNFS(MgrTestCase): def _test_delete_cluster(self): self._nfs_cmd('cluster', 'delete', self.cluster_id) - time.sleep(8) - orch_output = self._check_nfs_status() - self.assertEqual("No services reported\n", orch_output) + expected_output = "No services reported\n" + wait_time = 10 + while wait_time <= 60: + time.sleep(wait_time) + orch_output = self._check_nfs_status() + if expected_output == orch_output: + return + wait_time += 10 + self.fail("NFS Ganesha cluster could not be deleted") def _create_export(self, export_id, create_fs=False, extra_cmd=None): if create_fs: