Upgrade to Laravel 9 (#4413)
Co-authored-by: DaneEveritt <dane@daneeveritt.com>
This commit is contained in:
parent
95e15d2c8a
commit
cbcf62086f
573 changed files with 4387 additions and 9411 deletions
|
@ -18,10 +18,8 @@ class IsDigitTest extends TestCase
|
|||
|
||||
/**
|
||||
* Provide data to test against the helper function.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function helperDataProvider()
|
||||
public function helperDataProvider(): array
|
||||
{
|
||||
return [
|
||||
[true, false],
|
||||
|
|
|
@ -21,7 +21,7 @@ class AuthenticateUserTest extends MiddlewareTestCase
|
|||
}
|
||||
|
||||
/**
|
||||
* Test that a non-admin user results an an exception.
|
||||
* Test that a non-admin user results in an exception.
|
||||
*/
|
||||
public function testNonAdminUser()
|
||||
{
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
namespace Pterodactyl\Tests\Unit\Http\Middleware\Api\Daemon;
|
||||
|
||||
use Mockery as m;
|
||||
use Mockery\MockInterface;
|
||||
use Pterodactyl\Models\Node;
|
||||
use Illuminate\Contracts\Encryption\Encrypter;
|
||||
use Pterodactyl\Repositories\Eloquent\NodeRepository;
|
||||
|
@ -15,15 +16,9 @@ use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
|
|||
|
||||
class DaemonAuthenticateTest extends MiddlewareTestCase
|
||||
{
|
||||
/**
|
||||
* @var \Mockery\MockInterface
|
||||
*/
|
||||
private $repository;
|
||||
private MockInterface $encrypter;
|
||||
|
||||
/**
|
||||
* @var \Mockery\MockInterface
|
||||
*/
|
||||
private $encrypter;
|
||||
private MockInterface $repository;
|
||||
|
||||
/**
|
||||
* Setup tests.
|
||||
|
|
|
@ -3,16 +3,14 @@
|
|||
namespace Pterodactyl\Tests\Unit\Http\Middleware;
|
||||
|
||||
use Mockery as m;
|
||||
use Mockery\MockInterface;
|
||||
use Pterodactyl\Models\User;
|
||||
use Illuminate\Foundation\Application;
|
||||
use Pterodactyl\Http\Middleware\LanguageMiddleware;
|
||||
|
||||
class LanguageMiddlewareTest extends MiddlewareTestCase
|
||||
{
|
||||
/**
|
||||
* @var \Illuminate\Foundation\Application|\Mockery\Mock
|
||||
*/
|
||||
private $appMock;
|
||||
private MockInterface $appMock;
|
||||
|
||||
/**
|
||||
* Setup tests.
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
namespace Pterodactyl\Tests\Unit\Http\Middleware;
|
||||
|
||||
use Mockery as m;
|
||||
use Mockery\MockInterface;
|
||||
use Pterodactyl\Models\Node;
|
||||
use Illuminate\Http\Response;
|
||||
use Pterodactyl\Models\Server;
|
||||
|
@ -11,10 +12,7 @@ use Pterodactyl\Http\Middleware\MaintenanceMiddleware;
|
|||
|
||||
class MaintenanceMiddlewareTest extends MiddlewareTestCase
|
||||
{
|
||||
/**
|
||||
* @var \Illuminate\Contracts\Routing\ResponseFactory|\Mockery\Mock
|
||||
*/
|
||||
private $response;
|
||||
private MockInterface $response;
|
||||
|
||||
/**
|
||||
* Setup tests.
|
||||
|
|
|
@ -3,16 +3,14 @@
|
|||
namespace Pterodactyl\Tests\Unit\Http\Middleware;
|
||||
|
||||
use Mockery as m;
|
||||
use Mockery\MockInterface;
|
||||
use Illuminate\Auth\AuthManager;
|
||||
use Illuminate\Http\RedirectResponse;
|
||||
use Pterodactyl\Http\Middleware\RedirectIfAuthenticated;
|
||||
|
||||
class RedirectIfAuthenticatedTest extends MiddlewareTestCase
|
||||
{
|
||||
/**
|
||||
* @var \Illuminate\Auth\AuthManager|\Mockery\Mock
|
||||
*/
|
||||
private $authManager;
|
||||
private MockInterface $authManager;
|
||||
|
||||
/**
|
||||
* Setup tests.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue