Skip to content
Snippets Groups Projects
Unverified Commit 368f4076 authored by Roeland Jago Douma's avatar Roeland Jago Douma
Browse files

Fix getMock UtilTest

parent 206b48d2
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,14 @@ ...@@ -9,7 +9,14 @@
namespace Test; namespace Test;
use OC_Util; use OC_Util;
use OCP\App\IAppManager;
/**
* Class UtilTest
*
* @package Test
* @group DB
*/
class UtilTest extends \Test\TestCase { class UtilTest extends \Test\TestCase {
public function testGetVersion() { public function testGetVersion() {
$version = \OCP\Util::getVersion(); $version = \OCP\Util::getVersion();
...@@ -300,7 +307,7 @@ class UtilTest extends \Test\TestCase { ...@@ -300,7 +307,7 @@ class UtilTest extends \Test\TestCase {
$oldWebRoot = \OC::$WEBROOT; $oldWebRoot = \OC::$WEBROOT;
\OC::$WEBROOT = ''; \OC::$WEBROOT = '';
$appManager = $this->getMock('\OCP\App\IAppManager'); $appManager = $this->createMock(IAppManager::class);
$appManager->expects($this->any()) $appManager->expects($this->any())
->method('isEnabledForUser') ->method('isEnabledForUser')
->will($this->returnCallback(function($appId) use ($enabledApps){ ->will($this->returnCallback(function($appId) use ($enabledApps){
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment