def setUp(self): super(TestProcess, self).setUp() self.events_tester = ProcessListenerTester() self.proc = DummyProcessWithOutput.new() self.proc.add_process_listener(self.events_tester) self.executor = ThreadExecutor()
def setUp(self): import tempfile super(TestPicklePersistence, self).setUp() self.store_dir = tempfile.mkdtemp() self.pickle_persistence = PicklePersistence( running_directory=self.store_dir) self.procman = ThreadExecutor()
def __init__(self, executor=None, remove_on_terminate=True): """ :param executor: The executor used to play processes :param remove_on_terminate: Automatically remove any process that terminates from the control of this class. """ if executor is None: self._executor = ThreadExecutor() else: self._executor = executor self._processes = {} self._remove_on_terminate = remove_on_terminate
def setUp(self): super(TestWaitOnProcessStateEvent, self).setUp() self.executor = ThreadExecutor()
def setUp(self): self.assertEqual(len(MONITOR.get_pids()), 0) self.executor = ThreadExecutor()