diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2016-08-29 15:17:59 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2016-08-30 09:00:22 +0200 |
commit | 6a85882f610ed34c971a1510f5876f0564fd7612 (patch) | |
tree | a0d114b0e450f7b35d9eeb423171d4e7fe3d6767 /tests/Core | |
parent | 14136295b7568c6e34504c101eba0ee10f5c74fd (diff) | |
download | nextcloud-server-6a85882f610ed34c971a1510f5876f0564fd7612.tar.gz nextcloud-server-6a85882f610ed34c971a1510f5876f0564fd7612.zip |
Fix tests
Diffstat (limited to 'tests/Core')
-rw-r--r-- | tests/Core/Controller/AvatarControllerTest.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/Core/Controller/AvatarControllerTest.php b/tests/Core/Controller/AvatarControllerTest.php index fe1a44b28ab..af75c4bb751 100644 --- a/tests/Core/Controller/AvatarControllerTest.php +++ b/tests/Core/Controller/AvatarControllerTest.php @@ -31,6 +31,7 @@ function is_uploaded_file($filename) { namespace Tests\Core\Controller; +use OC\AppFramework\Utility\TimeFactory; use OC\Core\Controller\AvatarController; use OCP\AppFramework\Http; use OCP\Files\Cache\ICache; @@ -74,6 +75,8 @@ class AvatarControllerTest extends \Test\TestCase { private $logger; /** @var IRequest|\PHPUnit_Framework_MockObject_MockObject */ private $request; + /** @var TimeFactory|\PHPUnit_Framework_MockObject_MockObject */ + private $timeFactory; protected function setUp() { parent::setUp(); @@ -87,6 +90,7 @@ class AvatarControllerTest extends \Test\TestCase { $this->request = $this->getMockBuilder('OCP\IRequest')->getMock(); $this->rootFolder = $this->getMockBuilder('OCP\Files\IRootFolder')->getMock(); $this->logger = $this->getMockBuilder('OCP\ILogger')->getMock(); + $this->timeFactory = $this->getMockBuilder('OC\AppFramework\Utility\TimeFactory')->getMock(); $this->avatarMock = $this->getMockBuilder('OCP\IAvatar')->getMock(); $this->userMock = $this->getMockBuilder('OCP\IUser')->getMock(); @@ -100,7 +104,8 @@ class AvatarControllerTest extends \Test\TestCase { $this->userManager, $this->rootFolder, $this->logger, - 'userid' + 'userid', + $this->timeFactory ); // Configure userMock |