public function testWithoutPermissions() { \UsersLogin::logout(); // $route = new HtmlRoute($this->getConfigFixture()); $route->test($this->getRequestFixture()); $route->prepareRequest(); $route->dispatch(); $this->expectOutputRegex('#cms_auth#'); }
public function tearDown() { parent::tearDown(); \UsersLogin::logout(); }
protected function action() { if (\UsersLogin::isLogined()) { \UsersLogin::logout(); } }
public function unAuthorize($szUrl = '/') { $_SESSION[SESSION_AUTH] = array(); if (!headers_sent()) { header('HTTP/1.0 401 Unauthorized'); header('Content-Type: text/html; charset= utf-8'); header('Location: ' . $szUrl); } UsersLogin::logout(); }
/** * * @param unknown $code */ public function confirmEmail($code) { try { $acc = UserAccount::activateEmail($code); UsersLogin::logout(); UsersLogin::forceLogin($acc); $this->set('success', '1'); } catch (Exception $e) { $this->set('error', $e->getMessage()); } $this->output('users/registration/confirmEmail'); }
public function tearDown() { if (\UsersLogin::isLogined()) { \UsersLogin::logout(); } }