Merge "An alternate way to fix retype notifier test case"
This commit is contained in:
commit
0b70bd7046
@ -177,6 +177,12 @@ class GoogleBackupDriverTestCase(test.TestCase):
|
||||
for _i in range(0, 64):
|
||||
self.volume_file.write(os.urandom(units.Ki))
|
||||
self.size_volume_file += 1024
|
||||
# Note(yikun): It mocks out the backup notifier to avoid to leak
|
||||
# notifications into other test.
|
||||
notify_patcher = mock.patch(
|
||||
'cinder.volume.utils.notify_about_backup_usage')
|
||||
notify_patcher.start()
|
||||
self.addCleanup(notify_patcher.stop)
|
||||
|
||||
@gcs_client
|
||||
def test_backup(self):
|
||||
|
@ -67,6 +67,12 @@ class BackupNFSShareTestCase(test.TestCase):
|
||||
super(BackupNFSShareTestCase, self).setUp()
|
||||
self.ctxt = context.get_admin_context()
|
||||
self.mock_object(nfs, 'LOG')
|
||||
# Note(yikun): It mocks out the backup notifier to avoid to leak
|
||||
# notifications into other test.
|
||||
notify_patcher = mock.patch(
|
||||
'cinder.volume.utils.notify_about_backup_usage')
|
||||
notify_patcher.start()
|
||||
self.addCleanup(notify_patcher.stop)
|
||||
|
||||
def test_check_configuration_no_backup_share(self):
|
||||
self.override_config('backup_share', None)
|
||||
|
Loading…
x
Reference in New Issue
Block a user