MCPcopy Create free account
hub / github.com/celery/celery / test_election

Method test_election

t/unit/worker/test_control.py:327–334  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

325 assert 'some_key6' in x
326
327 def test_election(self):
328 consumer = Consumer(self.app)
329 panel = self.create_panel(consumer=consumer)
330 consumer.gossip = Mock()
331 panel.handle(
332 'election', {'id': 'id', 'topic': 'topic', 'action': 'action'},
333 )
334 consumer.gossip.election.assert_called_with('id', 'topic', 'action')
335
336 def test_election__no_gossip(self):
337 consumer = Mock(name='consumer')

Callers

nothing calls this directly

Calls 3

create_panelMethod · 0.95
ConsumerClass · 0.70
handleMethod · 0.45

Tested by

no test coverage detected