summaryrefslogtreecommitdiffstats
path: root/tests/settings
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2015-03-27 01:37:25 +0100
committerMorris Jobke <hey@morrisjobke.de>2015-03-27 11:30:32 +0100
commitb5545932e7efec24f36fae76ffe8924e31e1d55a (patch)
tree06a07a060082907df99afa3e7bbde31957189d53 /tests/settings
parent880b31c513eb755a057ca075d462e34ace911d0e (diff)
downloadnextcloud-server-b5545932e7efec24f36fae76ffe8924e31e1d55a.tar.gz
nextcloud-server-b5545932e7efec24f36fae76ffe8924e31e1d55a.zip
use StreamResponse to download the log file - fixes #14268
Diffstat (limited to 'tests/settings')
-rw-r--r--tests/settings/controller/logsettingscontrollertest.php12
1 files changed, 3 insertions, 9 deletions
diff --git a/tests/settings/controller/logsettingscontrollertest.php b/tests/settings/controller/logsettingscontrollertest.php
index 84581bf5782..60680ba4647 100644
--- a/tests/settings/controller/logsettingscontrollertest.php
+++ b/tests/settings/controller/logsettingscontrollertest.php
@@ -66,15 +66,9 @@ class LogSettingsControllerTest extends \Test\TestCase {
];
}
- public function testGetFilenameForDownload() {
- $timestamp = 42;
- $this->container['Config']
- ->expects($this->once())
- ->method('getSystemValue')
- ->with('instanceid')
- ->will($this->returnValue('0xF'));
- $filename = \Test_Helper::invokePrivate($this->logSettingsController, 'getFilenameForDownload', [$timestamp]);
+ public function testDownload() {
+ $response = $this->logSettingsController->download();
- $this->assertSame('ownCloud-0xF-42.log', $filename);
+ $this->assertInstanceOf('\OCP\AppFramework\Http\StreamResponse', $response);
}
}