Improved 404 page and updated tests for empty search
This commit is contained in:
parent
9a470b07fd
commit
f60a0c3b76
4 changed files with 15 additions and 6 deletions
|
@ -107,7 +107,7 @@ class ActivityService
|
|||
}
|
||||
|
||||
/**
|
||||
* Filters out similar acitivity.
|
||||
* Filters out similar activity.
|
||||
* @param Activity[] $activity
|
||||
* @return array
|
||||
*/
|
||||
|
|
|
@ -43,14 +43,14 @@
|
|||
<div class="float right">
|
||||
<div class="links text-center">
|
||||
<a href="/books"><i class="zmdi zmdi-book"></i>Books</a>
|
||||
@if($currentUser->can('settings-update'))
|
||||
@if(isset($currentUser) && $currentUser->can('settings-update'))
|
||||
<a href="/settings"><i class="zmdi zmdi-settings"></i>Settings</a>
|
||||
@endif
|
||||
@if(!$signedIn)
|
||||
@if(!isset($signedIn) || !$signedIn)
|
||||
<a href="/login"><i class="zmdi zmdi-sign-in"></i>Sign In</a>
|
||||
@endif
|
||||
</div>
|
||||
@if($signedIn)
|
||||
@if(isset($signedIn) && $signedIn)
|
||||
<div class="dropdown-container" dropdown>
|
||||
<span class="user-name" dropdown-toggle>
|
||||
<img class="avatar" src="{{$currentUser->getAvatar(30)}}" alt="{{ $currentUser->name }}">
|
||||
|
|
|
@ -4,8 +4,9 @@
|
|||
|
||||
|
||||
<div class="container">
|
||||
<h1>Page Not Found</h1>
|
||||
<p>The page you were looking for could not be found.</p>
|
||||
<h1 class="text-muted">Page Not Found</h1>
|
||||
<p>Sorry, The page you were looking for could not be found.</p>
|
||||
<a href="/" class="button">Return To Home</a>
|
||||
</div>
|
||||
|
||||
@stop
|
|
@ -180,6 +180,14 @@ class EntityTest extends TestCase
|
|||
->seeStatusCode(200);
|
||||
}
|
||||
|
||||
public function testEmptySearchRedirectsBack()
|
||||
{
|
||||
$this->asAdmin()
|
||||
->visit('/')
|
||||
->visit('/search/all')
|
||||
->seePageIs('/');
|
||||
}
|
||||
|
||||
|
||||
public function testEntitiesViewableAfterCreatorDeletion()
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue