mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 05:50:42 +02:00
[feature/passwords] Fix hash_test for use of passwords manager
PHPBB3-11610
This commit is contained in:
@@ -11,7 +11,7 @@ require_once dirname(__FILE__) . '/../../phpBB/includes/functions.php';
|
||||
|
||||
class phpbb_security_hash_test extends phpbb_test_case
|
||||
{
|
||||
public function test_check_hash_with_phpass()
|
||||
public function setUp()
|
||||
{
|
||||
global $phpbb_container;
|
||||
|
||||
@@ -39,7 +39,10 @@ class phpbb_security_hash_test extends phpbb_test_case
|
||||
->method('get')
|
||||
->with('passwords.manager')
|
||||
->will($this->returnValue($passwords_manager));
|
||||
}
|
||||
|
||||
public function test_check_hash_with_phpass()
|
||||
{
|
||||
$this->assertTrue(phpbb_check_hash('test', '$H$9isfrtKXWqrz8PvztXlL3.daw4U0zI1'));
|
||||
$this->assertTrue(phpbb_check_hash('test', '$P$9isfrtKXWqrz8PvztXlL3.daw4U0zI1'));
|
||||
$this->assertFalse(phpbb_check_hash('foo', '$H$9isfrtKXWqrz8PvztXlL3.daw4U0zI1'));
|
||||
|
Reference in New Issue
Block a user