Nothing to see here, move along

This commit is contained in:
2025-05-09 08:59:03 -04:00
parent 1e712069a1
commit db3d596be5
9 changed files with 337 additions and 78 deletions

View File

@@ -40,4 +40,16 @@ class JsonResponseFactoryTest extends TestCase
$data = ["invalid" => "\xB1\x31"];
JsonResponseFactory::createJsonResponse($data);
}
public function testCreateResponseReturnsValidResponse(): void
{
$code = 200;
$reasonPhrase = 'OK';
$factory = new JsonResponseFactory();
$response = $factory->createResponse($code, $reasonPhrase);
$this->assertSame($code, $response->getStatusCode());
$this->assertSame('application/json', $response->getHeaderLine('Content-Type'));
}
}