Ejemplo n.º 1
0
 /**
  * @test
  */
 public function shouldWaitAllTheItems()
 {
     $process = $this->getMockBuilder('\\Symfony\\Component\\Process\\Process')->disableOriginalConstructor()->getMock();
     $process->expects($this->exactly(5))->method('isTerminated')->willReturn(false)->willReturnOnConsecutiveCalls(false, false, false, true);
     $processes = new Processes(array($process));
     $this->assertTrue($processes->wait());
 }
Ejemplo n.º 2
0
 /**
  * @test
  */
 public function shouldWaitAllTheItems()
 {
     $process = $this->mockProcessWithExpectation('wait');
     $processes = new Processes(array($process));
     $this->assertTrue($processes->wait());
 }