cherrypy.test.test_states module

class cherrypy.test.test_states.Dependency(bus)[source]

Bases: object

graceful()[source]
start()[source]
startthread(thread_id)[source]
stop()[source]
stopthread(thread_id)[source]
subscribe()[source]
class cherrypy.test.test_states.PluginTests(methodName='runTest')[source]

Bases: cherrypy.test.helper.CPWebCase

test_daemonize()[source]
class cherrypy.test.test_states.ServerStateTests(methodName='runTest')[source]

Bases: cherrypy.test.helper.CPWebCase

setUp()[source]

Hook method for setting up the test fixture before exercising it.

static setup_server()
test_0_NormalStateFlow()[source]
test_1_Restart()[source]
test_2_KeyboardInterrupt()[source]
test_4_Autoreload()[source]
test_5_Start_Error()[source]
class cherrypy.test.test_states.SignalHandlingTests(methodName='runTest')[source]

Bases: cherrypy.test.helper.CPWebCase

_require_signal_and_kill(signal_name)[source]
test_SIGHUP_daemonized()[source]
test_SIGHUP_tty()[source]
test_SIGTERM()[source]

SIGTERM should shut down the server whether daemonized or not.

test_signal_handler_unsubscribe()[source]
cherrypy.test.test_states.setup_server()[source]
cherrypy.test.test_states.test_safe_wait_INADDR_ANY()[source]

Wait on INADDR_ANY should not raise IOError

In cases where the loopback interface does not exist, CherryPy cannot effectively determine if a port binding to INADDR_ANY was effected. In this situation, CherryPy should assume that it failed to detect the binding (not that the binding failed) and only warn that it could not verify it.