MCPcopy
hub / github.com/celery/celery / test_active

Method test_active

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

Source from the content-addressed store, hash-verified

308 self.panel.handle('report')
309
310 def test_active(self):
311 r = Request(
312 self.TaskMessage(self.mytask.name, 'do re mi'),
313 app=self.app,
314 )
315 worker_state.active_requests.add(r)
316 try:
317 assert self.panel.handle('dump_active')
318 finally:
319 worker_state.active_requests.discard(r)
320
321 def test_active_safe(self):
322 kwargsrepr = '<anything>'

Callers

nothing calls this directly

Calls 4

RequestClass · 0.90
addMethod · 0.45
handleMethod · 0.45
discardMethod · 0.45

Tested by

no test coverage detected