[Pkg-owncloud-commits] [owncloud] 04/34: Properly register sharing hooks and proxies
David Prévot
taffit at moszumanska.debian.org
Fri Nov 7 11:44:10 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository owncloud.
commit 43e01439d626b391ba5556a935b15d534ec555e8
Author: Vincent Petry <pvince81 at owncloud.com>
Date: Thu Oct 30 12:05:15 2014 +0100
Properly register sharing hooks and proxies
This will fix failing tests when shares weren't cleant up on delete due
to missing hooks.
Added login for user1 in setUp().
---
apps/files_encryption/tests/share.php | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/apps/files_encryption/tests/share.php b/apps/files_encryption/tests/share.php
index a55a4d4..abf8911 100755
--- a/apps/files_encryption/tests/share.php
+++ b/apps/files_encryption/tests/share.php
@@ -65,8 +65,10 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase {
// clear share hooks
\OC_Hook::clear('OCP\\Share');
+
+ // register share hooks
\OC::registerShareHooks();
- \OCP\Util::connectHook('OC_Filesystem', 'setup', '\OC\Files\Storage\Shared', 'setup');
+ \OCA\Files_Sharing\Helper::registerHooks();
// Sharing related hooks
\OCA\Encryption\Helper::registerShareHooks();
@@ -76,6 +78,7 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase {
// clear and register hooks
\OC_FileProxy::clearProxies();
+ \OC_FileProxy::register(new OCA\Files\Share\Proxy());
\OC_FileProxy::register(new OCA\Encryption\Proxy());
// create users
@@ -105,6 +108,9 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase {
// we don't want to tests with app files_trashbin enabled
\OC_App::disable('files_trashbin');
+
+ // login as first user
+ \Test_Encryption_Util::loginHelper(\Test_Encryption_Share::TEST_ENCRYPTION_SHARE_USER1);
}
function tearDown() {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git
More information about the Pkg-owncloud-commits
mailing list