. */ declare(strict_types=1); namespace Fisharebest\Webtrees\Http\RequestHandlers; use Fig\Http\Message\StatusCodeInterface; use Fisharebest\Webtrees\Services\MediaFileService; use Fisharebest\Webtrees\TestCase; /** * Test MediaController class. * * @covers \Fisharebest\Webtrees\Http\RequestHandlers\UploadMediaAction */ class UploadMediaActionTest extends TestCase { protected static $uses_database = true; /** * @return void */ public function testResponseIsOK(): void { $media_file_service = new MediaFileService(); $handler = new UploadMediaAction($media_file_service); $request = self::createRequest(); $response = $handler->handle($request); self::assertSame(StatusCodeInterface::STATUS_FOUND, $response->getStatusCode()); } }