X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fauth%2FLegacyHookPreAuthenticationProviderTest.php;h=b96455e09124c724929c24ccd20143ae1d18b9ca;hb=474b445a1df7a6ce0930dbe633e067c5df0ba712;hp=3548002682439e3cbf24763d2b8ba1902422623a;hpb=3eebaaffcf25c3779725309570de924ad5bea766;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/auth/LegacyHookPreAuthenticationProviderTest.php b/tests/phpunit/includes/auth/LegacyHookPreAuthenticationProviderTest.php index 3548002682..b96455e091 100644 --- a/tests/phpunit/includes/auth/LegacyHookPreAuthenticationProviderTest.php +++ b/tests/phpunit/includes/auth/LegacyHookPreAuthenticationProviderTest.php @@ -2,21 +2,14 @@ namespace MediaWiki\Auth; +use MediaWiki\MediaWikiServices; + /** * @group AuthManager * @group Database * @covers MediaWiki\Auth\LegacyHookPreAuthenticationProvider */ class LegacyHookPreAuthenticationProviderTest extends \MediaWikiTestCase { - protected function setUp() { - global $wgDisableAuthManager; - - parent::setUp(); - if ( $wgDisableAuthManager ) { - $this->markTestSkipped( '$wgDisableAuthManager is set' ); - } - } - /** * Get an instance of the provider * @return LegacyHookPreAuthenticationProvider @@ -26,7 +19,8 @@ class LegacyHookPreAuthenticationProviderTest extends \MediaWikiTestCase { $request->expects( $this->any() )->method( 'getIP' )->will( $this->returnValue( '127.0.0.42' ) ); $manager = new AuthManager( - $request, \ConfigFactory::getDefaultInstance()->makeConfig( 'main' ) + $request, + MediaWikiServices::getInstance()->getMainConfig() ); $provider = new LegacyHookPreAuthenticationProvider();