コード例 #1
0
ファイル: __init__.py プロジェクト: 585852/quantum-experiment
 def start(self):
     if self.state == 'before':
         self.process = Popen(self.args,
             stdout=blackhole, stderr=blackhole,
             env=os.environ,
             cwd=self.work_dir
         )
         self.notify_start(self.process.pid)
         self.poll = self.process.poll
     else:
         s = 'The process was already started and has state: %r' % self.state
         raise ProcessStateError(s)
コード例 #2
0
ファイル: __init__.py プロジェクト: vincentk/ipython
 def start(self):
     if self.state == 'before':
         # Store stdout & stderr to show with failing tests.
         # This is defined in IPython.testing.iptest
         self.process = Popen(self.args,
                              stdout=nose.iptest_stdstreams_fileno(),
                              stderr=STDOUT,
                              env=os.environ,
                              cwd=self.work_dir)
         self.notify_start(self.process.pid)
         self.poll = self.process.poll
     else:
         s = 'The process was already started and has state: %r' % self.state
         raise ProcessStateError(s)
コード例 #3
0
ファイル: __init__.py プロジェクト: pablooliveira/ipython
 def start(self):
     if self.state == 'before':
         self.process = Popen(self.args,
                              stdout=PIPE,
                              stderr=STDOUT,
                              env=os.environ,
                              cwd=self.work_dir)
         self.notify_start(self.process.pid)
         self.poll = self.process.poll
         # Store stdout & stderr to show with failing tests.
         # This is defined in IPython.testing.iptest
         nose.ipy_stream_capturer.add_stream(self.process.stdout.fileno())
         nose.ipy_stream_capturer.ensure_started()
     else:
         s = 'The process was already started and has state: %r' % self.state
         raise ProcessStateError(s)