mediawiki-extensions-Math/tests/phpunit/unit/InputCheckFactoryTest.php
libraryupgrader b409746fc6 build: Updating dependencies
composer:
* mediawiki/mediawiki-codesniffer: 36.0.0 → 37.0.0

npm:
* postcss: 7.0.35 → 7.0.36
  * https://npmjs.com/advisories/1693 (CVE-2021-23368)
* ws: 7.3.0 → 7.5.3
  * https://npmjs.com/advisories/1748 (CVE-2021-32640)
* glob-parent: 5.1.1 → 5.1.2
  * https://npmjs.com/advisories/1751 (CVE-2020-28469)
* trim-newlines: 3.0.0 → 3.0.1
  * https://npmjs.com/advisories/1753 (CVE-2021-33623)
* normalize-url: 4.5.0 → 4.5.1
  * https://npmjs.com/advisories/1755 (CVE-2021-33502)

Change-Id: Ie14979780cdbd04fa2804f5317e8b0f6b0029470
2021-07-23 02:28:22 +00:00

43 lines
1.1 KiB
PHP

<?php
use MediaWiki\Extension\Math\InputCheck\InputCheckFactory;
use MediaWiki\Extension\Math\InputCheck\MathoidChecker;
/**
* @covers \MediaWiki\Extension\Math\InputCheck\InputCheckFactory
*/
class InputCheckFactoryTest extends MediaWikiUnitTestCase {
use FactoryArgTestTrait;
protected static function getFactoryClass() {
return InputCheckFactory::class;
}
protected static function getInstanceClass() {
return MathoidChecker::class;
}
protected static function getExtraClassArgCount() {
return 2;
}
/**
* This is required since the FactoryArgTestTrait uses the full classname.
* Testing without overwriting this function would result in
*
* ReflectionException: Method MediaWiki\Extension\Math\InputCheck\InputCheckFactory::
* newMediaWiki\Extension\Math\InputCheck\MathoidChecker() does not exist
*
* see T253613
* @return string
*/
protected function getFactoryMethodName() {
return 'new' . ( new \ReflectionClass( MathoidChecker::class ) )->getShortName();
}
protected function setUp(): void {
parent::setUp();
$this->markTestSkipped( 'FactoryArgTestTrait can not yet handle the parameter numbers.' );
}
}