l.t.t.test_zope_test_in_subprocess : module documentation

Part of lp.testing.tests

Test lp.testing.ZopeTestInSubProcess.

How does it do this?

A TestCase, mixed-in with ZopeTestInSubProcess, is run by the Zope test runner. This test case sets its own layer, to keep track of the PIDs when certain methods are called. It also records pids for its own methods. Assertions are made as these methods are called to ensure that they are running in the correct process - the parent or the child.

Recording of the PIDs is handled using the record_pid decorator.

Function record_pid Decorator that records the pid at method invocation.
Class TestZopeTestInSubProcessLayer Helper to test ZopeTestInSubProcess.
Class TestZopeTestInSubProcess Test ZopeTestInSubProcess.
def record_pid(method):
Decorator that records the pid at method invocation.

Will probably only DTRT with class methods or bound instance methods.

API Documentation for Launchpad, generated by pydoctor at 2018-08-16 00:00:03.