1
0
Fork 0

Revert "Replace Module::init() with Constructors"

This commit is contained in:
Hypolite Petovan 2021-11-19 07:23:23 -05:00 committed by GitHub
commit 89d6c89b67
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
43 changed files with 921 additions and 1225 deletions

View file

@ -21,7 +21,6 @@
namespace Friendica\Test\src\Module\Api\Friendica\Photoalbum;
use Friendica\DI;
use Friendica\Module\Api\Friendica\Photoalbum\Update;
use Friendica\Network\HTTPException\BadRequestException;
use Friendica\Test\src\Module\Api\ApiTest;
@ -31,19 +30,19 @@ class UpdateTest extends ApiTest
public function testEmpty()
{
$this->expectException(BadRequestException::class);
(new Update(DI::l10n()))->rawContent();
(new Update())->rawContent();
}
public function testTooFewArgs()
{
$this->expectException(BadRequestException::class);
(new Update(DI::l10n(), ['album' => 'album_name']))->rawContent();
(new Update(['album' => 'album_name']))->rawContent();
}
public function testWrongUpdate()
{
$this->expectException(BadRequestException::class);
(new Update(DI::l10n(), ['album' => 'album_name', 'album_new' => 'album_name']))->rawContent();
(new Update(['album' => 'album_name', 'album_new' => 'album_name']))->rawContent();
}
public function testWithoutAuthenticatedUser()