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

Method test_dump_schedule

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

Source from the content-addressed store, hash-verified

563 worker_state.revoked.clear()
564
565 def test_dump_schedule(self):
566 consumer = Consumer(self.app)
567 panel = self.create_panel(consumer=consumer)
568 assert not panel.handle('dump_schedule')
569 r = Request(
570 self.TaskMessage(self.mytask.name, 'CAFEBABE'),
571 app=self.app,
572 )
573 consumer.timer.schedule.enter_at(
574 consumer.timer.Entry(lambda x: x, (r,)),
575 datetime.now() + timedelta(seconds=10))
576 consumer.timer.schedule.enter_at(
577 consumer.timer.Entry(lambda x: x, (object(),)),
578 datetime.now() + timedelta(seconds=10))
579 assert panel.handle('dump_schedule')
580
581 def test_dump_reserved(self):
582 consumer = Consumer(self.app)

Callers

nothing calls this directly

Calls 5

create_panelMethod · 0.95
RequestClass · 0.90
ConsumerClass · 0.70
handleMethod · 0.45
nowMethod · 0.45

Tested by

no test coverage detected