Merge "Add missing extra "greenthread" arg to remove_event()"

This commit is contained in:
Jenkins 2014-10-09 21:34:03 +00:00 committed by Gerrit Code Review
commit 12d5bf8373
2 changed files with 3 additions and 3 deletions

View File

@ -179,7 +179,7 @@ class ThreadGroupManager(object):
def add_event(self, stack_id, event):
self.events[stack_id].append(event)
def remove_event(self, stack_id, event):
def remove_event(self, gt, stack_id, event):
for e in self.events.pop(stack_id, []):
if e is not event:
self.add_event(stack_id, e)

View File

@ -3506,9 +3506,9 @@ class ThreadGroupManagerTest(HeatTestCase):
thm = service.ThreadGroupManager()
thm.add_event(stack_id, e1)
thm.add_event(stack_id, e2)
thm.remove_event(stack_id, e2)
thm.remove_event(None, stack_id, e2)
self.assertEqual(thm.events[stack_id], [e1])
thm.remove_event(stack_id, e1)
thm.remove_event(None, stack_id, e1)
self.assertNotIn(stack_id, thm.events)
def test_tgm_send(self):