summaryrefslogtreecommitdiffstats
path: root/apps/sharebymail/tests
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2017-03-30 15:23:44 +0200
committerBjoern Schiessle <bjoern@schiessle.org>2017-04-03 10:29:33 +0200
commitdac6826ad7ba54c5ed8bc81d09f2497ae2b0ec6f (patch)
tree86a0a5b4ffbcb37840ee301e9eec8e94245fd279 /apps/sharebymail/tests
parent99ebdc1111718848587d539b56a1d924ab48017a (diff)
downloadnextcloud-server-dac6826ad7ba54c5ed8bc81d09f2497ae2b0ec6f.tar.gz
nextcloud-server-dac6826ad7ba54c5ed8bc81d09f2497ae2b0ec6f.zip
setting to disable sending password by mail
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'apps/sharebymail/tests')
-rw-r--r--apps/sharebymail/tests/ShareByMailProviderTest.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/apps/sharebymail/tests/ShareByMailProviderTest.php b/apps/sharebymail/tests/ShareByMailProviderTest.php
index 013507fd35f..4ec62dc1a03 100644
--- a/apps/sharebymail/tests/ShareByMailProviderTest.php
+++ b/apps/sharebymail/tests/ShareByMailProviderTest.php
@@ -24,6 +24,7 @@ namespace OCA\ShareByMail\Tests;
use OC\HintException;
+use OCA\ShareByMail\Settings\SettingsManager;
use OCA\ShareByMail\ShareByMailProvider;
use OCP\Files\IRootFolder;
use OCP\IDBConnection;
@@ -80,6 +81,9 @@ class ShareByMailProviderTest extends TestCase {
/** @var \OCP\Activity\IManager | \PHPUnit_Framework_MockObject_MockObject */
private $activityManager;
+ /** @var SettingsManager | \PHPUnit_Framework_MockObject_MockObject */
+ private $settingsManager;
+
public function setUp() {
parent::setUp();
@@ -99,6 +103,7 @@ class ShareByMailProviderTest extends TestCase {
$this->urlGenerator = $this->getMockBuilder('\OCP\IUrlGenerator')->getMock();
$this->share = $this->getMockBuilder('\OCP\Share\IShare')->getMock();
$this->activityManager = $this->getMockBuilder('OCP\Activity\IManager')->getMock();
+ $this->settingsManager = $this->getMockBuilder(SettingsManager::class)->disableOriginalConstructor()->getMock();
$this->userManager->expects($this->any())->method('userExists')->willReturn(true);
}
@@ -140,7 +145,8 @@ class ShareByMailProviderTest extends TestCase {
$this->logger,
$this->mailer,
$this->urlGenerator,
- $this->activityManager
+ $this->activityManager,
+ $this->settingsManager
);
}