]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/tasks/mgr: regression test for 21260
authorJohn Spray <john.spray@redhat.com>
Thu, 7 Sep 2017 13:42:29 +0000 (09:42 -0400)
committerNathan Cutler <ncutler@suse.com>
Mon, 11 Sep 2017 09:50:13 +0000 (11:50 +0200)
(aka http://tracker.ceph.com/issues/21260)

Fixes: http://tracker.ceph.com/issues/21260
Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 28cb4bb2e68298a8a307eb2de6121b60db43cb86)

qa/tasks/mgr/test_failover.py

index c3ac7fb78be6e5baa19a9c2df5a1bc25e531dfa4..0dd9cb7e8bacb02e9c522020468ce927401bd716 100644 (file)
@@ -1,5 +1,6 @@
 
 import logging
+import json
 
 from tasks.mgr.mgr_test_case import MgrTestCase
 
@@ -92,6 +93,15 @@ class TestFailover(MgrTestCase):
             timeout=10
         )
 
+        # Both daemons should have fully populated metadata
+        # (regression test for http://tracker.ceph.com/issues/21260)
+        meta = json.loads(self.mgr_cluster.mon_manager.raw_cluster_cmd(
+            "mgr", "metadata"))
+        id_to_meta = dict([(i['id'], i) for i in meta])
+        for i in [original_active] + original_standbys:
+            self.assertIn(i, id_to_meta)
+            self.assertIn('ceph_version', id_to_meta[i])
+
         # We should be able to fail back over again: the exercises
         # our re-initialization of the python runtime within
         # a single process lifetime.