Ejemplo n.º 1
0
 /**
  * @return void
  */
 public function testIsAuthorizedWithYvesCredentialsFromConfigMustReturnTrue()
 {
     $token = new StaticToken();
     $authConfig = Config::get(AuthConstants::AUTH_DEFAULT_CREDENTIALS);
     $rawToken = $authConfig['yves_system']['token'];
     $token->setRawToken($rawToken);
     $hash = $token->generate();
     $isAllowed = $this->authFacade->isAuthenticated($hash);
     $this->assertTrue($isAllowed);
 }
Ejemplo n.º 2
0
 /**
  * @return void
  */
 public function testValidatePasswordWhenTokenProvidedNotSavedToDatabase()
 {
     $resetStatus = $this->authFacade->isValidPasswordResetToken('NERAMANES');
     $this->assertFalse($resetStatus);
 }