self.stubs.Set(volume_types, 'destroy',
return_volume_types_with_volumes_destroy)
req = fakes.HTTPRequest.blank('/v2/fake/types/1')
- self.assertEquals(len(test_notifier.NOTIFICATIONS), 0)
+ self.assertEqual(len(test_notifier.NOTIFICATIONS), 0)
self.controller._delete(req, 1)
- self.assertEquals(len(test_notifier.NOTIFICATIONS), 1)
+ self.assertEqual(len(test_notifier.NOTIFICATIONS), 1)
def test_create(self):
self.stubs.Set(volume_types, 'create',
'id': '1',
'created_at': datetime.datetime(1, 1, 1, 1, 1, 1),
'size': 1}}
- self.assertEquals(res_dict, expected)
+ self.assertEqual(res_dict, expected)
def test_update_empty_body(self):
body = {}
}
],
}}
- self.assertEquals(res_dict, expected)
+ self.assertEqual(res_dict, expected)
def test_update_empty_body(self):
body = {}
rem = self.service._delete_backup_snapshot(mock_rados(), base_name,
self.backup_id)
- self.assertEquals(rem, (snap_name, 0))
+ self.assertEqual(rem, (snap_name, 0))
def test_try_delete_base_image_diff_format(self):
# don't create volume db entry since it should not be required
self.stubs.Set(self.volume.driver, '_is_cloneable', lambda x: False)
image_loc = (object(), object())
actual = self.volume.driver.clone_image(object(), image_loc, object())
- self.assertEquals(expected, actual)
+ self.assertEqual(expected, actual)
self.stubs.Set(self.volume.driver, '_is_cloneable', lambda x: True)
self.assertEqual(expected,
self.stubs.Set(self.volume.driver, '_clone', lambda *args: None)
self.stubs.Set(self.volume.driver, '_resize', lambda *args: None)
actual = self.volume.driver.clone_image(object(), image_loc, object())
- self.assertEquals(expected, actual)
+ self.assertEqual(expected, actual)
def test_clone_success(self):
self.stubs.Set(self.volume.driver, '_is_cloneable', lambda x: True)