Fix tests

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2017-08-06 14:25:10 +02:00
parent bf06ec29ca
commit 9cfb561c1c
2 changed files with 4 additions and 2 deletions

View File

@@ -24,6 +24,7 @@
namespace OCA\Deck\Controller;
use OCA\Deck\Db\Acl;
use OCP\IUser;
class BoardControllerTest extends \PHPUnit_Framework_TestCase {
@@ -61,11 +62,12 @@ class BoardControllerTest extends \PHPUnit_Framework_TestCase {
->disableOriginalConstructor()
->getMock();
$user = $this->createMock(IUser::class);
$this->groupManager->method('getUserGroupIds')
->willReturn(['admin', 'group1', 'group2']);
$this->userManager->method('get')
->with($this->userId)
->willReturn('user');
->willReturn($user);
$this->controller = new BoardController(
'deck',