Пример #1
0
 public function testPush()
 {
     $data = [['instance' => $this->getControllerMock(), 'action' => 'test1'], ['instance' => $this->getControllerMock(), 'action' => 'test2'], ['instance' => $this->getControllerMock(), 'action' => 'test3']];
     $chain = new Chain();
     foreach ($data as $item) {
         $chain->push($item['instance'], $item['action']);
     }
     $this->assertChain($chain, $data);
 }