Adjust tests

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2018-09-05 14:53:17 +02:00
parent 2d545aafa5
commit 4c300bf432

View File

@@ -24,6 +24,7 @@
namespace OCA\Deck\Service;
use OCA\Deck\Activity\ActivityManager;
use OCA\Deck\AppInfo\Application;
use OCA\Deck\Db\Acl;
use OCA\Deck\Db\Attachment;
@@ -65,6 +66,8 @@ class AttachmentServiceTest extends TestCase {
private $attachmentService;
/** @var MockObject */
private $attachmentServiceImpl;
/** @var ActivityManager */
private $activityManager;
private $appContainer;
/** ICache */
private $cache;
@@ -85,7 +88,8 @@ class AttachmentServiceTest extends TestCase {
$this->permissionService = $this->createMock(PermissionService::class);
$this->application = $this->createMock(Application::class);
$this->cacheFactory = $this->createMock(ICacheFactory::class);
$this->activityManager = $this->createMock(ActivityManager::class);
$this->cache = $this->createMock(ICache::class);
$this->cacheFactory->expects($this->any())->method('createDistributed')->willReturn($this->cache);
@@ -96,7 +100,7 @@ class AttachmentServiceTest extends TestCase {
$this->l10n = $this->createMock(IL10N::class);
$this->attachmentService = new AttachmentService($this->attachmentMapper, $this->cardMapper, $this->permissionService, $this->application, $this->cacheFactory, $this->userId, $this->l10n);
$this->attachmentService = new AttachmentService($this->attachmentMapper, $this->cardMapper, $this->permissionService, $this->application, $this->cacheFactory, $this->userId, $this->l10n, $this->activityManager);
}
public function testRegisterAttachmentService() {