X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;ds=sidebyside;f=tests%2Fphpunit%2Fincludes%2Fauth%2FCheckBlocksSecondaryAuthenticationProviderTest.php;h=e8b61c59c61423a8a8d164b3b34e4dc04518fa72;hb=61a7a5463de9c4d1073f3c0fd17b35b797923c2d;hp=4e44547bbf6d4312fe84bba910f73d141a63b8ed;hpb=803f3867b7fcbb5fcee405f5c10cfa06cb857bd6;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/auth/CheckBlocksSecondaryAuthenticationProviderTest.php b/tests/phpunit/includes/auth/CheckBlocksSecondaryAuthenticationProviderTest.php index 4e44547bbf..e8b61c59c6 100644 --- a/tests/phpunit/includes/auth/CheckBlocksSecondaryAuthenticationProviderTest.php +++ b/tests/phpunit/includes/auth/CheckBlocksSecondaryAuthenticationProviderTest.php @@ -76,6 +76,7 @@ class CheckBlocksSecondaryAuthenticationProviderTest extends \MediaWikiTestCase $blockOptions = [ 'address' => 'UTBlockee', 'user' => $user->getID(), + 'by' => $this->getTestSysop()->getUser()->getId(), 'reason' => __METHOD__, 'expiry' => time() + 100500, 'createAccount' => true, @@ -149,6 +150,7 @@ class CheckBlocksSecondaryAuthenticationProviderTest extends \MediaWikiTestCase $blockOptions = [ 'address' => '127.0.0.0/24', 'reason' => __METHOD__, + 'by' => $this->getTestSysop()->getUser()->getId(), 'expiry' => time() + 100500, 'createAccount' => true, ]; @@ -163,6 +165,7 @@ class CheckBlocksSecondaryAuthenticationProviderTest extends \MediaWikiTestCase $user->saveSettings(); } $this->setMwGlobals( [ 'wgUser' => $user ] ); + \RequestContext::getMain()->setUser( $user ); $newuser = \User::newFromName( 'RandomUser' ); $provider = new CheckBlocksSecondaryAuthenticationProvider(