Example #1
0
 public function testCreateSalt()
 {
     //Simple test to ensure salts are non-null and different with each call
     $salt1 = PasswordUtil::createSalt();
     $this->assertNotNull($salt1);
     for ($i = 0; $i < 1000; $i++) {
         $this->assertNotEquals(PasswordUtil::createSalt(), PasswordUtil::createSalt());
     }
 }