mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 18:03:17 +00:00
Remove DeliverDataInterface::deliverData as never used
This commit is contained in:
@@ -139,21 +139,4 @@ class ServeFileResponseFactoryTest extends \PhraseanetWebTestCase
|
||||
$this->assertEquals('attachment; filename="PhraseanetTestCase.php"', $response->headers->get('content-disposition'));
|
||||
$this->assertEquals(realpath($file), $response->headers->get('x-accel-redirect'));
|
||||
}
|
||||
|
||||
public function testDeliverDatas()
|
||||
{
|
||||
$this->factory = new ServeFileResponseFactory(new \unicode());
|
||||
|
||||
$data = 'Sex,Name,Birthday
|
||||
M,Alphonse,1932
|
||||
F,Béatrice,1964
|
||||
F,Charlotte,1988';
|
||||
|
||||
$response = $this->factory->deliverData($data, 'data.csv', 'text/csv', 'attachment');
|
||||
|
||||
$this->assertInstanceOf('Symfony\Component\HttpFoundation\Response', $response);
|
||||
$this->assertEquals('attachment; filename="data.csv"', $response->headers->get('content-disposition'));
|
||||
$this->assertEquals('text/csv', $response->headers->get('content-type'));
|
||||
$this->assertEquals($data, $response->getContent());
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user