Merge "Add sg name in after delete event kwargs" into stable/train
This commit is contained in:
commit
169535b155
@ -271,6 +271,7 @@ class SecurityGroupDbMixin(ext_sg.SecurityGroupPluginBase,
|
||||
sg.delete()
|
||||
|
||||
kwargs.pop('security_group')
|
||||
kwargs['name'] = sg['name']
|
||||
registry.notify(resources.SECURITY_GROUP, events.AFTER_DELETE,
|
||||
self, **kwargs)
|
||||
|
||||
|
@ -354,7 +354,8 @@ class SecurityGroupDbMixinTestCase(testlib_api.SqlTestCase):
|
||||
mock.call('security_group', 'after_delete',
|
||||
mock.ANY, context=mock.ANY,
|
||||
security_group_id=sg_dict['id'],
|
||||
security_group_rule_ids=[mock.ANY, mock.ANY])])
|
||||
security_group_rule_ids=[mock.ANY, mock.ANY],
|
||||
name=sg_dict['name'])])
|
||||
|
||||
def test_security_group_rule_precommit_create_event_fail(self):
|
||||
registry.subscribe(fake_callback, resources.SECURITY_GROUP_RULE,
|
||||
|
Loading…
x
Reference in New Issue
Block a user