diff options
Diffstat (limited to 'tests/phpunit/includes/api/ApiUserrightsTest.php')
-rw-r--r-- | tests/phpunit/includes/api/ApiUserrightsTest.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/phpunit/includes/api/ApiUserrightsTest.php b/tests/phpunit/includes/api/ApiUserrightsTest.php index 5889f8265ac2..a1bafed78ca4 100644 --- a/tests/phpunit/includes/api/ApiUserrightsTest.php +++ b/tests/phpunit/includes/api/ApiUserrightsTest.php @@ -1,5 +1,7 @@ <?php +use MediaWiki\Block\DatabaseBlock; + /** * @group API * @group Database @@ -128,7 +130,7 @@ class ApiUserrightsTest extends ApiTestCase { public function testBlockedWithUserrights() { global $wgUser; - $block = new Block( [ 'address' => $wgUser, 'by' => $wgUser->getId(), ] ); + $block = new DatabaseBlock( [ 'address' => $wgUser, 'by' => $wgUser->getId(), ] ); $block->insert(); try { @@ -144,7 +146,7 @@ class ApiUserrightsTest extends ApiTestCase { $this->setPermissions( true, true ); - $block = new Block( [ 'address' => $user, 'by' => $user->getId() ] ); + $block = new DatabaseBlock( [ 'address' => $user, 'by' => $user->getId() ] ); $block->insert(); try { |