From: John Spray Date: Thu, 5 Nov 2015 01:15:57 +0000 (+0000) Subject: tasks/cephfs: fix race in test_sessionmap X-Git-Tag: v10.2.6~165^2^2~267^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c713423bd18a68ec39e89ad328ca97c186a93094;p=ceph.git tasks/cephfs: fix race in test_sessionmap Fixes: #13698 Signed-off-by: John Spray --- diff --git a/tasks/cephfs/test_sessionmap.py b/tasks/cephfs/test_sessionmap.py index 70ee1984dde0..5b0bae4ade98 100644 --- a/tasks/cephfs/test_sessionmap.py +++ b/tasks/cephfs/test_sessionmap.py @@ -73,7 +73,10 @@ class TestSessionMap(CephFSTestCase): # dirty) # The number of writes is two per session, because the header (sessionmap version) update and # KV write both count. - self.assertEqual(get_omap_wrs() - initial_omap_wrs, 2) + self.wait_until_true( + lambda: get_omap_wrs() - initial_omap_wrs == 2, + timeout=10 # Long enough for an export to get acked + ) # Now end our sessions and check the backing sessionmap is updated correctly self.mount_a.umount_wait()