X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/33a2999a57854495fcea8c1acf1b75b04a28a0bf..refs/pull/494/head:/tests/UserProfileTest.php diff --git a/tests/UserProfileTest.php b/tests/UserProfileTest.php index 12f88483f..eabfce004 100644 --- a/tests/UserProfileTest.php +++ b/tests/UserProfileTest.php @@ -94,5 +94,27 @@ class UserProfileTest extends BrowserKitTest ->seePageIs('/settings/users/' . $guestUser->id) ->see('cannot delete the guest user'); } - + + public function test_books_view_is_list() + { + $editor = $this->getEditor([ + 'books_view_type' => 'list' + ]); + + $this->actingAs($editor) + ->visit('/books') + ->pageNotHasElement('.featured-image-container') + ->pageHasElement('.entity-list-item'); + } + + public function test_books_view_is_grid() + { + $editor = $this->getEditor([ + 'books_view_type' => 'grid' + ]); + + $this->actingAs($editor) + ->visit('/books') + ->pageHasElement('.featured-image-container'); + } }