ApiTestCase: Drop testApiTestGroup forcing use of medium/large

We do not encourage people to use these groups, they are not widely used,
and this is just forcing cruft into code for no value.

Change-Id: Ia58aa62ea6a1694694fb54acbd717181cd36e051
This commit is contained in:
James D. Forrester 2022-08-11 11:33:58 -04:00
parent d3c1cc94c6
commit b251f3750f

View file

@ -3,8 +3,6 @@
use MediaWiki\MediaWikiServices;
use MediaWiki\Permissions\Authority;
use MediaWiki\Session\SessionManager;
use PHPUnit\Framework\Assert;
use PHPUnit\Util\Test;
abstract class ApiTestCase extends MediaWikiLangTestCase {
protected static $apiUrl;
@ -183,20 +181,6 @@ abstract class ApiTestCase extends MediaWikiLangTestCase {
);
}
/**
* @coversNothing
*/
public function testApiTestGroup() {
$groups = Test::getGroups( static::class );
$constraint = Assert::logicalOr(
$this->contains( 'medium' ),
$this->contains( 'large' )
);
$this->assertThat( $groups, $constraint,
'ApiTestCase::setUp can be slow, tests must be "medium" or "large"'
);
}
/**
* Expect an ApiUsageException to be thrown with the given parameters, which are the same as
* ApiUsageException::newWithMessage()'s parameters. This allows checking for an exception