'The Janitor will kill processes during reactor cleanup.'

def test_cleanReactorKillsProcesses(self):

    @implementer(IProcessTransport)
    class StubProcessTransport(object, ):
        '\n                                                A    stub    L{IProcessTransport}    provider    which    records    signals.\n                                                @ivar    signals:    The    signals    passed    to    L{signalProcess}.\n                                                '
        def __init__(self):
            self.signals = []
        def signalProcess(self, signal):
            '\n                                                                Append    C{signal}    to    C{self.signals}.\n                                                                '
            self.signals.append(signal)
    pt = StubProcessTransport()
    reactor = StubReactor([], [pt])
    jan = _Janitor(None, None, reactor=reactor)
    jan._cleanReactor()
    self.assertEqual(pt.signals, ['KILL'])
