9 class ApiDisabledTest
extends ApiTestCase
{
10 public function testDisabled() {
11 $this->mergeMwGlobalArrayValue( 'wgAPIModules',
12 [ 'login' => 'ApiDisabled' ] );
14 $this->setExpectedException( ApiUsageException
::class,
15 'The "login" module has been disabled.' );
17 $this->doApiRequest( [ 'action' => 'login' ] );