public function testForwardController() { $this->controller->init(); $this->appMock->expects($this->once())->method('getCurrentAction')->will($this->returnValue([['module' => 'Module1', 'controller' => 'index', 'action' => 'index']])); $this->appMock->expects($this->once())->method('dispatchAction')->with(['module' => 'Module1', 'controller' => 'index', 'action' => 'forwarded']); $this->controller->forwardController('index', 'forwarded'); }