X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fapi%2FApiQueryUserInfoTest.php;h=556818e85e1639f4f0caa71ee80662d8fe019d0b;hb=cceade3a0f57ffe488d26950cefca68f9e4daa02;hp=7dcb75c486018b52723628b2748eb7b61bc569fd;hpb=07bb67286b87ee8fbe0325264b63d11be48de765;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/api/ApiQueryUserInfoTest.php b/tests/phpunit/includes/api/ApiQueryUserInfoTest.php index 7dcb75c486..556818e85e 100644 --- a/tests/phpunit/includes/api/ApiQueryUserInfoTest.php +++ b/tests/phpunit/includes/api/ApiQueryUserInfoTest.php @@ -1,17 +1,21 @@ hideDeprecated( 'ApiQueryUserInfo::getBlockInfo' ); + $apiQueryUserInfo = new ApiQueryUserInfo( new ApiQuery( new ApiMain( $this->apiContext ), 'userinfo' ), 'userinfo' ); - $block = new Block(); + $block = new DatabaseBlock(); $info = $apiQueryUserInfo->getBlockInfo( $block ); $subset = [ 'blockid' => null, @@ -25,12 +29,14 @@ class ApiQueryUserInfoTest extends ApiTestCase { } public function testGetBlockInfoPartial() { + $this->hideDeprecated( 'ApiQueryUserInfo::getBlockInfo' ); + $apiQueryUserInfo = new ApiQueryUserInfo( new ApiQuery( new ApiMain( $this->apiContext ), 'userinfo' ), 'userinfo' ); - $block = new Block( [ + $block = new DatabaseBlock( [ 'sitewide' => false, ] ); $info = $apiQueryUserInfo->getBlockInfo( $block );