X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fapi%2FApiOpenSearchTest.php;h=23fa7bcb25fda5b64098254dd18d8f4cc3ea99f8;hb=3e83a502135337fafb1c72ae7300afa368d434b0;hp=39e90c2e33afd70b371bff380542f2830b8da0b5;hpb=a7c3aaccba03062e8b27ff378e74619e339325ba;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/api/ApiOpenSearchTest.php b/tests/phpunit/includes/api/ApiOpenSearchTest.php index 39e90c2e33..23fa7bcb25 100644 --- a/tests/phpunit/includes/api/ApiOpenSearchTest.php +++ b/tests/phpunit/includes/api/ApiOpenSearchTest.php @@ -1,7 +1,5 @@ replaceSearchEngineConfig(); @@ -9,11 +7,12 @@ class ApiOpenSearchTest extends MediaWikiTestCase { ->method( 'getSearchTypes' ) ->will( $this->returnValue( [ 'the one ring' ] ) ); + $api = $this->createApi(); $engine = $this->replaceSearchEngine(); $engine->expects( $this->any() ) ->method( 'getProfiles' ) ->will( $this->returnValueMap( [ - [ SearchEngine::COMPLETION_PROFILE_TYPE, [ + [ SearchEngine::COMPLETION_PROFILE_TYPE, $api->getUser(), [ [ 'name' => 'normal', 'desc-message' => 'normal-message', @@ -26,7 +25,6 @@ class ApiOpenSearchTest extends MediaWikiTestCase { ] ], ] ) ); - $api = $this->createApi(); $params = $api->getAllowedParams(); $this->assertArrayNotHasKey( 'offset', $params );