mirror of
https://github.com/friendica/friendica
synced 2025-04-23 19:10:13 +00:00
41 lines
1.1 KiB
PHP
41 lines
1.1 KiB
PHP
<?php
|
|
|
|
// Copyright (C) 2010-2024, the Friendica project
|
|
// SPDX-FileCopyrightText: 2010-2024 the Friendica project
|
|
//
|
|
// SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
namespace Friendica\Test\src\Module\Api\Twitter\Blocks;
|
|
|
|
use Friendica\DI;
|
|
use Friendica\Module\Api\Twitter\Blocks\Lists;
|
|
use Friendica\Test\ApiTestCase;
|
|
|
|
class ListsTest extends ApiTestCase
|
|
{
|
|
/**
|
|
* Test the api_statuses_f() function.
|
|
*/
|
|
public function testApiStatusesFWithBlocks()
|
|
{
|
|
$response = (new Lists(DI::mstdnError(), DI::appHelper(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), []))
|
|
->run($this->httpExceptionMock);
|
|
|
|
$json = $this->toJson($response);
|
|
|
|
self::assertIsArray($json->users);
|
|
}
|
|
|
|
/**
|
|
* Test the api_blocks_list() function an undefined cursor GET variable.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function testApiBlocksListWithUndefinedCursor()
|
|
{
|
|
self::markTestIncomplete('Needs refactoring of Lists - replace filter_input() with $request parameter checks');
|
|
|
|
// $_GET['cursor'] = 'undefined';
|
|
// self::assertFalse(api_blocks_list('json'));
|
|
}
|
|
}
|