getPasswordMode() public method

public getPasswordMode ( ) : TUserManagerPasswordMode
return TUserManagerPasswordMode how password is stored, clear text, or MD5 or SHA1 hashed. Default to TUserManagerPasswordMode::MD5.
コード例 #1
0
ファイル: TUserManagerTest.php プロジェクト: pradosoft/prado
 public function testPasswordMode()
 {
     $userManager = new TUserManager();
     $userManager->setPasswordMode('Clear');
     self::assertEquals('Clear', $userManager->getPasswordMode());
     $userManager->setPasswordMode('MD5');
     self::assertEquals('MD5', $userManager->getPasswordMode());
     $userManager->setPasswordMode('SHA1');
     self::assertEquals('SHA1', $userManager->getPasswordMode());
     try {
         $userManager->setPasswordMode('Invalid');
         self::fail('Exception TInvalidDataValueException not thrown');
     } catch (TInvalidDataValueException $e) {
     }
 }