mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-18 22:33:44 +02:00
Return Http test cases to a passing state
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace Tests\Unit\Http\Middleware;
|
||||
|
||||
use Illuminate\Auth\AuthenticationException;
|
||||
use Pterodactyl\Http\Middleware\Authenticate;
|
||||
|
||||
class AuthenticateTest extends MiddlewareTestCase
|
||||
@@ -18,11 +19,11 @@ class AuthenticateTest extends MiddlewareTestCase
|
||||
|
||||
/**
|
||||
* Test that a logged out user results in an exception.
|
||||
*
|
||||
* @expectedException \Illuminate\Auth\AuthenticationException
|
||||
*/
|
||||
public function testLoggedOutUser()
|
||||
{
|
||||
$this->expectException(AuthenticationException::class);
|
||||
|
||||
$this->request->shouldReceive('user')->withNoArgs()->once()->andReturnNull();
|
||||
|
||||
$this->getMiddleware()->handle($this->request, $this->getClosureAssertions());
|
||||
|
||||
Reference in New Issue
Block a user