[ticket/11620] More mock provider methods

The mock provider object now better matches the interface
given for providers.

PHPBB3-11620
This commit is contained in:
Andy Chase 2013-07-08 10:28:40 -07:00
parent a1168972ff
commit 3999d7ec7c

View file

@ -10,21 +10,43 @@
/** /**
* Mock provider class with basic functions to help test * Mock provider class with basic functions to help test
* sessions. * sessions.
*
* See interface here:
* includes/auth/provider/interface.php
*/ */
class phpbb_provider { class phpbb_provider {
function init()
{
return null;
}
function login($username, $password)
{
return array(
'status' => "",
'error_msg' => "",
'user_row' => "",
);
}
function autologin() function autologin()
{ {
return array(); return array();
} }
function kill() function acp($new)
{ {
return array();
} }
function validate_session($data) function logout($data, $new_session)
{ {
return true; return null;
}
function validate_session($user)
{
return null;
} }
} }