Merge "Use _show_resource() of super class"
This commit is contained in:
commit
12cc65b2d1
@ -198,11 +198,6 @@ class MonascaAlarmDefinition(resource.Resource):
|
||||
self.client().alarm_definitions.delete(
|
||||
alarm_id=self.resource_id)
|
||||
|
||||
# FIXME(kanagaraj-manickam) Remove this method once monasca defect 1484900
|
||||
# is fixed.
|
||||
def _show_resource(self):
|
||||
return self.client().alarm_definitions.get(self.resource_id)
|
||||
|
||||
|
||||
def resource_mapping():
|
||||
return {
|
||||
|
@ -186,11 +186,6 @@ class MonascaNotification(resource.Resource):
|
||||
self.client().notifications.delete(
|
||||
notification_id=self.resource_id)
|
||||
|
||||
# FIXME(kanagaraj-manickam) Remove this method once monasca defect 1484900
|
||||
# is fixed.
|
||||
def _show_resource(self):
|
||||
return self.client().notifications.get(self.resource_id)
|
||||
|
||||
|
||||
def resource_mapping():
|
||||
return {
|
||||
|
@ -198,11 +198,3 @@ class MonascaAlarmDefinitionTest(common.HeatTestCase):
|
||||
mock_alarm_delete = self.test_client.alarm_definitions.delete
|
||||
mock_alarm_delete.side_effect = client_plugin.monasca_exc.NotFound
|
||||
self.assertIsNone(self.test_resource.handle_delete())
|
||||
|
||||
def test_resource_show_resource(self):
|
||||
mock_notification_get = self.test_client.alarm_definitions.get
|
||||
mock_notification_get.return_value = {}
|
||||
|
||||
self.assertEqual({},
|
||||
self.test_resource._show_resource(),
|
||||
'Failed to show resource')
|
||||
|
@ -286,11 +286,3 @@ class MonascaNotificationTest(common.HeatTestCase):
|
||||
client_plugin.monasca_exc.NotFound)
|
||||
|
||||
self.assertIsNone(self.test_resource.handle_delete())
|
||||
|
||||
def test_resource_show_resource(self):
|
||||
mock_notification_get = self.test_client.notifications.get
|
||||
mock_notification_get.return_value = {}
|
||||
|
||||
self.assertEqual({},
|
||||
self.test_resource._show_resource(),
|
||||
'Failed to show resource')
|
||||
|
Loading…
Reference in New Issue
Block a user