mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[feature/passwords] Fix tests for PHP version < 5.3.7
PHPBB3-11610
This commit is contained in:
parent
3f70699aa3
commit
13d25e6a32
1 changed files with 18 additions and 6 deletions
|
@ -45,12 +45,24 @@ class phpbb_crypto_manager_test extends PHPUnit_Framework_TestCase
|
||||||
|
|
||||||
public function hash_password_data()
|
public function hash_password_data()
|
||||||
{
|
{
|
||||||
return array(
|
if (version_compare(PHP_VERSION, '5.3.7', '<'))
|
||||||
array('', '2y', 60),
|
{
|
||||||
array('crypto.driver.bcrypt_2y', '2y', 60),
|
return array(
|
||||||
array('crypto.driver.bcrypt', '2a', 60),
|
array('', '2a', 60),
|
||||||
array('crypto.driver.salted_md5', 'H', 34),
|
array('crypto.driver.bcrypt_2y', '2a', 60),
|
||||||
);
|
array('crypto.driver.bcrypt', '2a', 60),
|
||||||
|
array('crypto.driver.salted_md5', 'H', 34),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return array(
|
||||||
|
array('', '2y', 60),
|
||||||
|
array('crypto.driver.bcrypt_2y', '2y', 60),
|
||||||
|
array('crypto.driver.bcrypt', '2a', 60),
|
||||||
|
array('crypto.driver.salted_md5', 'H', 34),
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Reference in a new issue