Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2018-05-17 12:46:28 +0300
committerJulius Härtl <jus@bitgrid.net>2018-05-17 13:21:57 +0300
commit5b3ca8f7c69f5fd44e0970f2bf10eb3ba4dad7ab (patch)
treefaf21d3bf4e277406d9a448a1b8c93705e505fb2 /apps/theming/tests
parent2bf51c7b9eee1da51e7c0f7a5cbcd76d06fdc9fa (diff)
Add Content-Disposition header
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps/theming/tests')
-rw-r--r--apps/theming/tests/Controller/ThemingControllerTest.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/theming/tests/Controller/ThemingControllerTest.php b/apps/theming/tests/Controller/ThemingControllerTest.php
index 6d756c13a5a..eddf5bc56dc 100644
--- a/apps/theming/tests/Controller/ThemingControllerTest.php
+++ b/apps/theming/tests/Controller/ThemingControllerTest.php
@@ -305,7 +305,7 @@ class ThemingControllerTest extends TestCase {
$destination = \OC::$server->getTempManager()->getTemporaryFolder();
touch($tmpLogo);
- copy(__DIR__ . '/../../../../tests/data/testimagelarge.svg', $tmpLogo);
+ copy(__DIR__ . '/../../../../tests/data/testimage.png', $tmpLogo);
$this->request
->expects($this->at(0))
->method('getParam')
@@ -701,6 +701,7 @@ class ThemingControllerTest extends TestCase {
$expected->addHeader('Expires', $expires->format(\DateTime::RFC2822));
$expected->addHeader('Pragma', 'cache');
$expected->addHeader('Content-Type', 'text/svg');
+ $expected->addHeader('Content-Disposition', 'attachment; filename="logo"');
@$this->assertEquals($expected, $this->themingController->getImage('logo'));
}
@@ -733,6 +734,7 @@ class ThemingControllerTest extends TestCase {
$expected->addHeader('Expires', $expires->format(\DateTime::RFC2822));
$expected->addHeader('Pragma', 'cache');
$expected->addHeader('Content-Type', 'image/png');
+ $expected->addHeader('Content-Disposition', 'attachment; filename="background"');
@$this->assertEquals($expected, $this->themingController->getImage('background'));
}