]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
tasks/cephfs: add test case auth_list helper
authorJohn Spray <john.spray@redhat.com>
Mon, 9 Nov 2015 13:17:25 +0000 (13:17 +0000)
committerJohn Spray <john.spray@redhat.com>
Thu, 14 Jan 2016 22:55:29 +0000 (22:55 +0000)
Signed-off-by: John Spray <john.spray@redhat.com>
tasks/cephfs/cephfs_test_case.py

index 846cf8d2c32543810ab0b774db7cc194f9cb3291..500cd765589d272f55f93c1d8773cf83a4350aac 100644 (file)
@@ -170,6 +170,14 @@ class CephFSTestCase(unittest.TestCase):
         self.configs_set.add((subsys, key))
         self.fs.set_ceph_conf(subsys, key, value)
 
+    def auth_list(self):
+        """
+        Convenience wrapper on "ceph auth list"
+        """
+        return json.loads(self.fs.mon_manager.raw_cluster_cmd(
+            "auth", "list", "--format=json-pretty"
+        ))['auth_dump']
+
     def assert_session_count(self, expected, ls_data=None, mds_id=None):
         if ls_data is None:
             ls_data = self.fs.mds_asok(['session', 'ls'], mds_id=mds_id)