summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2017-01-09 21:10:11 +0100
committerGitHub <noreply@github.com>2017-01-09 21:10:11 +0100
commit307d45e3bdf32c50e46a47b746282ecfbb43b384 (patch)
tree4ee9ab5b6a40472f20c2fa13461ed0c06ff79643 /tests
parent9a5b9d8555c89293073af17f8a2c1ebf3c64de8d (diff)
parent817e974c5ffc2de4732316114fdcb4f30ac292de (diff)
downloadnextcloud-server-307d45e3bdf32c50e46a47b746282ecfbb43b384.tar.gz
nextcloud-server-307d45e3bdf32c50e46a47b746282ecfbb43b384.zip
Merge pull request #2987 from nextcloud/no-empty-bundle
dont write a certificate bundle if the shipped ca bundle is empty
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/Security/CertificateManagerTest.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/lib/Security/CertificateManagerTest.php b/tests/lib/Security/CertificateManagerTest.php
index 92a063d47c7..408e65c6766 100644
--- a/tests/lib/Security/CertificateManagerTest.php
+++ b/tests/lib/Security/CertificateManagerTest.php
@@ -8,8 +8,10 @@
namespace Test\Security;
+use OC\Files\Storage\Temporary;
use \OC\Security\CertificateManager;
use OCP\IConfig;
+use OCP\ILogger;
/**
* Class CertificateManagerTest
@@ -43,7 +45,7 @@ class CertificateManagerTest extends \Test\TestCase {
$config->expects($this->any())->method('getSystemValue')
->with('installed', false)->willReturn(true);
- $this->certificateManager = new CertificateManager($this->username, new \OC\Files\View(), $config);
+ $this->certificateManager = new CertificateManager($this->username, new \OC\Files\View(), $config, $this->createMock(ILogger::class));
}
protected function tearDown() {
@@ -143,7 +145,7 @@ class CertificateManagerTest extends \Test\TestCase {
/** @var CertificateManager | \PHPUnit_Framework_MockObject_MockObject $certificateManager */
$certificateManager = $this->getMockBuilder('OC\Security\CertificateManager')
- ->setConstructorArgs([$uid, $view, $config])
+ ->setConstructorArgs([$uid, $view, $config, $this->createMock(ILogger::class)])
->setMethods(['getFilemtimeOfCaBundle', 'getCertificateBundle'])
->getMock();
@@ -210,5 +212,4 @@ class CertificateManagerTest extends \Test\TestCase {
[null, 10, 5, 8, false, true],
];
}
-
}