Introduce FixtureTest::useHttpMethod for manually overwrite the HTTP Method argument

This commit is contained in:
Philipp 2022-01-02 22:51:16 +01:00
parent 4e67bfed8d
commit 5e85939502
No known key found for this signature in database
GPG key ID: 24A7501396EB5432
36 changed files with 175 additions and 82 deletions

View file

@ -17,7 +17,7 @@ class MentionsTest extends ApiTest
*/
public function testApiStatusesMentions()
{
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), ['REQUEST_METHOD' => Router::GET]))
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), []))
->run([
'max_id' => 10
]);
@ -35,7 +35,7 @@ class MentionsTest extends ApiTest
*/
public function testApiStatusesMentionsWithNegativePage()
{
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), ['REQUEST_METHOD' => Router::GET]))
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), []))
->run([
'page' => -2
]);
@ -67,7 +67,7 @@ class MentionsTest extends ApiTest
*/
public function testApiStatusesMentionsWithRss()
{
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), ['REQUEST_METHOD' => Router::GET], ['extension' => ICanCreateResponses::TYPE_RSS]))
$response = (new Mentions(DI::app(), DI::l10n(), DI::baseUrl(), DI::args(), DI::logger(), DI::profiler(), DI::apiResponse(), [], ['extension' => ICanCreateResponses::TYPE_RSS]))
->run([
'page' => -2
]);