Use regular groups endpoint to support Nextcloud 13
Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
@@ -65,6 +65,10 @@ class PageControllerTest extends \Test\TestCase {
|
||||
->method('checkFirstRun')
|
||||
->willReturn(true);
|
||||
|
||||
$this->permissionService->expects($this->any())
|
||||
->method('canCreate')
|
||||
->willReturn(true);
|
||||
|
||||
$this->defaultBoardService->expects($this->once())
|
||||
->method('createDefaultBoard')
|
||||
->willReturn($board);
|
||||
@@ -73,6 +77,29 @@ class PageControllerTest extends \Test\TestCase {
|
||||
$this->assertEquals('main', $response->getTemplateName());
|
||||
}
|
||||
|
||||
public function testIndexOnFirstRunNoCreate() {
|
||||
|
||||
$board = new Board();
|
||||
$board->setTitle('Personal');
|
||||
$board->setOwner($this->userId);
|
||||
$board->setColor('000000');
|
||||
|
||||
$this->defaultBoardService->expects($this->once())
|
||||
->method('checkFirstRun')
|
||||
->willReturn(true);
|
||||
|
||||
$this->permissionService->expects($this->any())
|
||||
->method('canCreate')
|
||||
->willReturn(false);
|
||||
|
||||
$this->defaultBoardService->expects($this->never())
|
||||
->method('createDefaultBoard')
|
||||
->willReturn($board);
|
||||
|
||||
$response = $this->controller->index();
|
||||
$this->assertEquals('main', $response->getTemplateName());
|
||||
}
|
||||
|
||||
public function testIndexOnSecondRun() {
|
||||
|
||||
$this->config->setUserValue($this->userId, 'deck', 'firstRun', 'no');
|
||||
|
||||
Reference in New Issue
Block a user