Browse Source

updated Aauth/LoginTest

v3-dev
REJack 6 years ago
parent
commit
3cb5b1376f
No known key found for this signature in database
GPG Key ID: 4A44B48700429F46
  1. 4
      tests/Aauth/Libraries/Aauth/LoginTest.php

4
tests/Aauth/Libraries/Aauth/LoginTest.php

@ -110,7 +110,7 @@ class LoginTest extends CIDatabaseTestCase
$config = new AauthConfig();
$config->loginUseUsername = true;
$this->library = new Aauth($config, $session);
$this->assertFalse($this->library->login('admin', 'password'));
$this->assertFalse($this->library->login('admin', 'passwor'));
$this->assertEquals(lang('Aauth.loginFailedUsername'), $this->library->getErrorsArray()[0]);
}
@ -166,6 +166,7 @@ class LoginTest extends CIDatabaseTestCase
$this->library->login('[email protected]', 'password123456');
$this->library->login('[email protected]', 'password123456');
$this->library->login('[email protected]', 'password123456');
$this->library->login('[email protected]', 'password123456');
$this->assertFalse($this->library->login('[email protected]', 'password123456'));
$this->assertEquals(lang('Aauth.loginAttemptsExceeded'), $this->library->getErrorsArray()[0]);
}
@ -189,6 +190,7 @@ class LoginTest extends CIDatabaseTestCase
]);
$this->assertTrue($this->library->isLoggedIn());
$this->library->logout();
$this->library = new Aauth(null, $session);
$this->assertFalse($this->library->isLoggedIn());
}
}

Loading…
Cancel
Save