mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-28 17:02:04 +03:00
Extracted entity testcase methods to own class
Also added some new fetch helper methods for future use.
This commit is contained in:
@ -210,7 +210,7 @@ class PagesApiTest extends TestCase
|
||||
$this->actingAsApiEditor();
|
||||
$page = Page::visible()->first();
|
||||
$chapter = Chapter::visible()->where('book_id', '!=', $page->book_id)->first();
|
||||
$this->setEntityRestrictions($chapter, ['view'], [$this->getEditor()->roles()->first()]);
|
||||
$this->entities->setPermissions($chapter, ['view'], [$this->getEditor()->roles()->first()]);
|
||||
$details = [
|
||||
'name' => 'My updated API page',
|
||||
'chapter_id' => $chapter->id,
|
||||
|
Reference in New Issue
Block a user