예제 #1
0
 public function let(LoggerInterface $logger, DeployStep $step1, DeployStep $step2, Local $server1, Local $server2)
 {
     $server1->getTitle()->willReturn('app1');
     $server2->getTitle()->willReturn('app2');
     $step1->getTitle()->willReturn('Step 1');
     $step1->getServers()->willReturn([]);
     $step2->getTitle()->willReturn('Step 2');
     $step2->getServers()->willReturn([]);
     $step1->getServers()->willReturn([$server1, $server2]);
     $step2->getServers()->willReturn([$server1]);
     $step1->getCommands()->willReturn(['echo "step 1: command 1"', 'echo "step 1: command 2"']);
     $step2->getCommands()->willReturn(['echo "step 2: command 1"', 'echo "step 2: command 2"']);
     $steps = [$step1, $step2];
     $this->beConstructedWith($steps, $logger);
 }