]> BookStack Code Mirror - bookstack/blobdiff - tests/UserProfileTest.php
Added Swedish locale to config
[bookstack] / tests / UserProfileTest.php
index 4636fc76cf5b3747fed6a0ae45a6357896c9a7f6..3262117d5009e0bfd5bb8f9aa2b71886fbf4bf6e 100644 (file)
@@ -97,21 +97,19 @@ class UserProfileTest extends BrowserKitTest
 
     public function test_books_view_is_list()
     {
-        $editor = $this->getEditor([
-          'books_view_type' => 'list'
-        ]);
+        $editor = $this->getEditor();
+        setting()->putUser($editor, 'books_view_type', 'list');
 
         $this->actingAs($editor)
             ->visit('/books')
             ->pageNotHasElement('.featured-image-container')
-            ->pageHasElement('.entity-list-item');
+            ->pageHasElement('.content .entity-list-item');
     }
 
     public function test_books_view_is_grid()
     {
-        $editor = $this->getEditor([
-          'books_view_type' => 'grid'
-        ]);
+        $editor = $this->getEditor();
+        setting()->putUser($editor, 'books_view_type', 'grid');
 
         $this->actingAs($editor)
             ->visit('/books')