1
1
Fork 0
friendica_2019-12_sharedHos.../tests/Util/authtest/authtest.php

22 lines
550 B
PHP
Raw Normal View History

<?php
/**
* Name: TEST-ADDON: Authentication "allow all"
* Description: For testing purpose only
* Version: 1.0
* Author: Philipp Holzer <admin@philipp.info>
*/
use Friendica\Core\Hook;
use Friendica\Model\User;
function authtest_install()
{
Hook::register('authenticate', 'tests/Util/authtest/authtest.php', 'authtest_authenticate');
}
function authtest_authenticate($a,&$b)
{
2021-11-30 20:53:47 +01:00
$b['authenticated'] = \Friendica\Test\Util\AuthTestConfig::$authenticated;
$b['user_record'] = User::getById(\Friendica\Test\Util\AuthTestConfig::$user_id);
}