def testSendBuffered(self):
     b = FakeWorkerBuilder(False, self.basedir)
     s = runprocess.RunProcess(b, stdoutCommand('hello'), self.basedir)
     s._addToBuffers('stdout', 'hello ')
     s._addToBuffers('stdout', 'world')
     s._sendBuffers()
     self.failUnlessEqual(b.updates, [{'stdout': 'hello world'}], b.show())
 def testSendStatus(self):
     b = FakeWorkerBuilder(False, self.basedir)
     s = runprocess.RunProcess(b, stdoutCommand('hello'), self.basedir)
     s.sendStatus({'stdout': nl('hello\n')})
     self.failUnlessEqual(b.updates, [{'stdout': nl('hello\n')}], b.show())