]> BookStack Code Mirror - bookstack/blobdiff - tests/Actions/WebhookFormatTesting.php
Guest create page: name field autofocus
[bookstack] / tests / Actions / WebhookFormatTesting.php
index 35467a76a7ba1c7a8a80e3e8e1c9d2112d1f6a92..07341c75b2431a8c2d4fe7a33439b652d92ff6ba 100644 (file)
@@ -5,9 +5,6 @@ namespace Tests\Actions;
 use BookStack\Actions\ActivityType;
 use BookStack\Actions\Webhook;
 use BookStack\Actions\WebhookFormatter;
-use BookStack\Entities\Models\Book;
-use BookStack\Entities\Models\Chapter;
-use BookStack\Entities\Models\Page;
 use Illuminate\Support\Arr;
 use Tests\TestCase;
 
@@ -16,9 +13,9 @@ class WebhookFormatTesting extends TestCase
     public function test_entity_events_show_related_user_info()
     {
         $events = [
-            ActivityType::BOOK_UPDATE    => Book::query()->first(),
-            ActivityType::CHAPTER_CREATE => Chapter::query()->first(),
-            ActivityType::PAGE_MOVE      => Page::query()->first(),
+            ActivityType::BOOK_UPDATE    => $this->entities->book(),
+            ActivityType::CHAPTER_CREATE => $this->entities->chapter(),
+            ActivityType::PAGE_MOVE      => $this->entities->page(),
         ];
 
         foreach ($events as $event => $entity) {