mirror of
https://github.com/friendica/friendica
synced 2025-04-23 23:50:12 +00:00
Adapt tests to use new BaseURL UriInterface
This commit is contained in:
parent
402d45d490
commit
9e6d95284b
7 changed files with 15 additions and 22 deletions
|
@ -21,12 +21,9 @@
|
|||
|
||||
namespace Friendica\Test\src\Module\Api\GnuSocial\GnuSocial;
|
||||
|
||||
use Friendica\App\BaseURL;
|
||||
use Friendica\App\Router;
|
||||
use Friendica\DI;
|
||||
use Friendica\Module\Api\GNUSocial\GNUSocial\Config;
|
||||
use Friendica\Test\src\Module\Api\ApiTest;
|
||||
use Friendica\Test\Util\VFSTrait;
|
||||
|
||||
class ConfigTest extends ApiTest
|
||||
{
|
||||
|
@ -35,13 +32,11 @@ class ConfigTest extends ApiTest
|
|||
*/
|
||||
public function testApiStatusnetConfig()
|
||||
{
|
||||
DI::config()->set('system', 'ssl_policy', BaseURL::SSL_POLICY_FULL);
|
||||
|
||||
$response = (new Config(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), []))
|
||||
->run($this->httpExceptionMock);
|
||||
$json = $this->toJson($response);
|
||||
|
||||
self::assertEquals(DI::config()->get('config', 'hostname'), $json->site->server);
|
||||
self::assertEquals(DI::baseUrl()->getHost(), $json->site->server);
|
||||
self::assertEquals(DI::config()->get('system', 'theme'), $json->site->theme);
|
||||
self::assertEquals(DI::baseUrl() . '/images/friendica-64.png', $json->site->logo);
|
||||
self::assertTrue($json->site->fancy);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue