mirror of
https://github.com/ceph/ceph
synced 2025-01-21 02:31:19 +00:00
tasks/cephfs: reset IDs of mounts between tests
because volumeclient test twiddles the IDs to match the auth identities it creates. Signed-off-by: John Spray <john.spray@redhat.com>
This commit is contained in:
parent
7a19b6dc0d
commit
b94b35b68f
@ -140,6 +140,12 @@ class CephFSTestCase(unittest.TestCase):
|
||||
'mon', 'allow r',
|
||||
'osd', 'allow rw pool={0}'.format(self.fs.get_data_pool_name()))
|
||||
|
||||
log.info(client_mount_ids)
|
||||
|
||||
# In case the test changes the IDs of clients, stash them so that we can
|
||||
# reset in tearDown
|
||||
self._original_client_ids = client_mount_ids
|
||||
|
||||
# In case there were any extra auth identities around from a previous
|
||||
# test, delete them
|
||||
for entry in self.auth_list():
|
||||
@ -171,6 +177,9 @@ class CephFSTestCase(unittest.TestCase):
|
||||
for m in self.mounts:
|
||||
m.teardown()
|
||||
|
||||
for i, m in enumerate(self.mounts):
|
||||
m.client_id = self._original_client_ids[i]
|
||||
|
||||
for subsys, key in self.configs_set:
|
||||
self.fs.clear_ceph_conf(subsys, key)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user