summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/tests/UpdaterTest.php
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2020-07-22 22:11:01 +0200
committerMorris Jobke <hey@morrisjobke.de>2020-07-23 22:03:14 +0200
commite84504c4d6a079d55d2f78ad21b1ad20d53035bb (patch)
treeb1ac43a8573169257ee0c8d56d1dfd406cf68f59 /apps/files_sharing/tests/UpdaterTest.php
parentc842678f0a1fb65981a03302895192ddc58479c9 (diff)
downloadnextcloud-server-e84504c4d6a079d55d2f78ad21b1ad20d53035bb.tar.gz
nextcloud-server-e84504c4d6a079d55d2f78ad21b1ad20d53035bb.zip
Use IBootstrap for the files_trashbin app
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps/files_sharing/tests/UpdaterTest.php')
-rw-r--r--apps/files_sharing/tests/UpdaterTest.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/apps/files_sharing/tests/UpdaterTest.php b/apps/files_sharing/tests/UpdaterTest.php
index 30efbac533d..344c08bea48 100644
--- a/apps/files_sharing/tests/UpdaterTest.php
+++ b/apps/files_sharing/tests/UpdaterTest.php
@@ -31,6 +31,8 @@
namespace OCA\Files_Sharing\Tests;
+use OCA\Files_Trashbin\AppInfo\Application;
+use OCP\AppFramework\Bootstrap\IBootContext;
use OCP\Share\IShare;
/**
@@ -77,8 +79,9 @@ class UpdaterTest extends TestCase {
$status = \OC::$server->getAppManager()->isEnabledForUser('files_trashbin');
(new \OC_App())->enable('files_trashbin');
-
- \OCA\Files_Trashbin\Trashbin::registerHooks();
+ // register trashbin hooks
+ $trashbinApp = new Application();
+ $trashbinApp->boot($this->createMock(IBootContext::class));
$fileinfo = \OC\Files\Filesystem::getFileInfo($this->folder);
$this->assertTrue($fileinfo instanceof \OC\Files\FileInfo);