Part of lp.testing View In Hierarchy
Known subclasses: lp.bugs.scripts.checkwatches.tests.test_core.TestTwistedThreadScheduler, lp.bugs.scripts.checkwatches.tests.test_core.TestTwistedThreadSchedulerInPlace, lp.services.job.tests.test_runner.TestTwistedJobRunner, lp.testing.tests.test_zope_test_in_subprocess.TestZopeTestInSubProcess
Use this as a mixin with an interesting
TestCase to isolate
tests with side-effects. Each and every test method in the test
case is run in a new, forked, sub-process. This will slow down
your tests, so use it sparingly. However, when you need to, for
example, start the Twisted reactor (which cannot currently be
safely stopped and restarted in process) it is invaluable.
This is basically a reimplementation of subunit's
IsolatedTestSuite, but adjusted to work
with Zope. In particular, Zope's TestResult object is responsible
for calling testSetUp() and testTearDown() on the selected layer.