コード例 #1
0
 def test_verify_long_password_strict(self):
     self.config_fixture.config(strict_password_check=False)
     self.config_fixture.config(group='identity', max_password_length=5)
     max_length = CONF.identity.max_password_length
     invalid_password = '******'
     trunc = common_utils.verify_length_and_trunc_password(invalid_password)
     self.assertEqual(invalid_password[:max_length], trunc)
コード例 #2
0
ファイル: test_utils.py プロジェクト: mahak/keystone
 def test_verify_long_password_strict(self):
     self.config_fixture.config(strict_password_check=False)
     self.config_fixture.config(group='identity', max_password_length=5)
     max_length = CONF.identity.max_password_length
     invalid_password = '******'
     trunc = common_utils.verify_length_and_trunc_password(invalid_password)
     self.assertEqual(invalid_password[:max_length], trunc)
コード例 #3
0
 def test_verify_normal_password_strict(self):
     self.config_fixture.config(strict_password_check=False)
     password = uuid.uuid4().hex
     verified = common_utils.verify_length_and_trunc_password(password)
     self.assertEqual(password, verified)
コード例 #4
0
ファイル: test_utils.py プロジェクト: mahak/keystone
 def test_verify_normal_password_strict(self):
     self.config_fixture.config(strict_password_check=False)
     password = uuid.uuid4().hex
     verified = common_utils.verify_length_and_trunc_password(password)
     self.assertEqual(password, verified)