phpstan update
Better typying
This commit is contained in:
parent
74db3b9ad0
commit
6adc1df213
17 changed files with 166 additions and 158 deletions
|
@ -6,6 +6,7 @@
|
|||
|
||||
namespace Alltube\Test;
|
||||
|
||||
use Alltube\Controller\BaseController;
|
||||
use Alltube\Controller\DownloadController;
|
||||
use Alltube\Controller\FrontController;
|
||||
use Alltube\LocaleManager;
|
||||
|
@ -44,6 +45,7 @@ abstract class ControllerTest extends BaseTest
|
|||
|
||||
/**
|
||||
* Controller instance used in tests.
|
||||
* @var BaseController
|
||||
*/
|
||||
protected $controller;
|
||||
|
||||
|
@ -80,7 +82,7 @@ abstract class ControllerTest extends BaseTest
|
|||
* Run controller function with custom query parameters and return the result.
|
||||
*
|
||||
* @param string $request Controller function to call
|
||||
* @param array $params Query parameters
|
||||
* @param mixed[] $params Query parameters
|
||||
*
|
||||
* @return Response HTTP response
|
||||
*/
|
||||
|
@ -96,7 +98,7 @@ abstract class ControllerTest extends BaseTest
|
|||
* Assert that calling controller function with these parameters returns a 200 HTTP response.
|
||||
*
|
||||
* @param string $request Controller function to call
|
||||
* @param array $params Query parameters
|
||||
* @param mixed[] $params Query parameters
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
@ -109,7 +111,7 @@ abstract class ControllerTest extends BaseTest
|
|||
* Assert that calling controller function with these parameters returns an HTTP redirect.
|
||||
*
|
||||
* @param string $request Controller function to call
|
||||
* @param array $params Query parameters
|
||||
* @param mixed[] $params Query parameters
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
@ -122,7 +124,7 @@ abstract class ControllerTest extends BaseTest
|
|||
* Assert that calling controller function with these parameters returns an HTTP 500 error.
|
||||
*
|
||||
* @param string $request Controller function to call
|
||||
* @param array $params Query parameters
|
||||
* @param mixed[] $params Query parameters
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
@ -135,7 +137,7 @@ abstract class ControllerTest extends BaseTest
|
|||
* Assert that calling controller function with these parameters returns an HTTP 400 error.
|
||||
*
|
||||
* @param string $request Controller function to call
|
||||
* @param array $params Query parameters
|
||||
* @param mixed[] $params Query parameters
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
|
|
@ -17,6 +17,12 @@ use Slim\Http\Request;
|
|||
*/
|
||||
class FrontControllerTest extends ControllerTest
|
||||
{
|
||||
/**
|
||||
* Controller instance used in tests.
|
||||
* @var FrontController
|
||||
*/
|
||||
protected $controller;
|
||||
|
||||
/**
|
||||
* Prepare tests.
|
||||
* @throws Exception
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
namespace Alltube\Test;
|
||||
|
||||
use Psr\Http\Message\StreamInterface;
|
||||
use RuntimeException;
|
||||
|
||||
/**
|
||||
|
@ -15,6 +16,7 @@ abstract class StreamTest extends BaseTest
|
|||
{
|
||||
/**
|
||||
* Stream instance.
|
||||
* @var StreamInterface
|
||||
*/
|
||||
protected $stream;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue