mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-11-28 09:20:42 +00:00
bdeec56d1f
Change-Id: Ifa2f8a47fbd0bdd20334f59dd06a21339b9a4292
24 lines
447 B
PHP
24 lines
447 B
PHP
<?php
|
|
|
|
/**
|
|
* Test the Id feature
|
|
*
|
|
* @covers MathRenderer
|
|
*
|
|
* @group Math
|
|
*
|
|
* @licence GNU GPL v2+
|
|
*/
|
|
class MathIdTest extends MediaWikiTestCase {
|
|
|
|
/**
|
|
* Checks if the id specified as attribute is set in the renderer object
|
|
*/
|
|
public function testBasics() {
|
|
define( 'RANDOM_ID', 'a_random_id' );
|
|
$renderer = MathRenderer::getRenderer( "a+b", [ 'id' => RANDOM_ID ] );
|
|
$this->assertEquals( RANDOM_ID, $renderer->getID() );
|
|
}
|
|
|
|
}
|