MCPcopy
hub / github.com/benoitc/gunicorn / test_shutdown_quick

Method test_shutdown_quick

tests/ctl/test_handlers.py:398–408  ·  view source on GitHub ↗

Test quick shutdown.

(self)

Source from the content-addressed store, hash-verified

396 mock_kill.assert_called_once_with(12345, signal.SIGTERM)
397
398 def test_shutdown_quick(self):
399 """Test quick shutdown."""
400 arbiter = MockArbiter()
401 handlers = CommandHandlers(arbiter)
402
403 with patch('os.kill') as mock_kill:
404 result = handlers.shutdown("quick")
405
406 assert result["status"] == "shutting_down"
407 assert result["mode"] == "quick"
408 mock_kill.assert_called_once_with(12345, signal.SIGINT)
409
410
411class TestShowAll:

Callers

nothing calls this directly

Calls 3

shutdownMethod · 0.95
CommandHandlersClass · 0.90
MockArbiterClass · 0.70

Tested by

no test coverage detected