コード例 #1
0
ファイル: LogoutController.php プロジェクト: omusico/zf2-demo
 public function indexAction()
 {
     try {
         $this->service->logout();
         return $this->redirect()->toRoute('home');
     } catch (\Exception $e) {
         return $this->flashMessenger()->addErrorMessage('An unexpected error has occurred, please contact your system administrator');
     }
 }
コード例 #2
0
 public function testLogout()
 {
     $this->authenticationServiceMock->expects($this->once())->method('clearIdentity');
     $this->testedObject->logout();
 }