mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-09-23 10:21:31 +00:00
Fix Pilcrow size
* Pilcrow was very big, see test on MatTestNative page: * " \amalg \P \S \% \dagger \ddagger \ldots \cdots " * and add specific testcase Bug : T315978 Change-Id: I3074f3782ef821e7f9813b79a570bbd51ead28db
This commit is contained in:
parent
d109aec95e
commit
586d15b046
|
@ -654,10 +654,12 @@ class BaseParsing {
|
|||
|
||||
switch ( $name ) {
|
||||
case "oint":
|
||||
case "\\P":
|
||||
$mo = new MMLmo();
|
||||
return $mrow->encapsulateRaw( $mStyle->encapsulateRaw(
|
||||
$mo->encapsulateRaw( MMLutil::uc2xNotation( $uc ) ) ) );
|
||||
case "\\P":
|
||||
$mo = new MMLmo();
|
||||
return $mo->encapsulateRaw( MMLutil::uc2xNotation( $uc ) );
|
||||
case "oiint":
|
||||
case "oiiint":
|
||||
case "ointctrclockwise":
|
||||
|
|
|
@ -15,16 +15,22 @@ use MediaWikiUnitTestCase;
|
|||
*/
|
||||
class MMLRenderTest extends MediaWikiUnitTestCase {
|
||||
|
||||
public function testPilcrow() {
|
||||
$input = "\P";
|
||||
$mathMLtexVC = $this->generateMML( $input );
|
||||
$this->assertStringContainsString( "<mo>¶</mo>\n</math>", $mathMLtexVC );
|
||||
}
|
||||
|
||||
public function testLesserThan() {
|
||||
$input = "<, \\nless,";
|
||||
$mathMLtexVC = $this->generateMML( $input );
|
||||
$this->assertTrue( str_contains( $mathMLtexVC, " <mo><</mo>" ) );
|
||||
$this->assertStringContainsString( "<mo><</mo>", $mathMLtexVC );
|
||||
}
|
||||
|
||||
public function testSidesetError() {
|
||||
$input = "\\sideset{_1^2}{_3^4}";
|
||||
$mathMLtexVC = $this->generateMML( $input );
|
||||
$this->assertTrue( str_contains( $mathMLtexVC, "merror" ) );
|
||||
$this->assertStringContainsString( "merror", $mathMLtexVC );
|
||||
}
|
||||
|
||||
public function testSidesetSum() {
|
||||
|
|
Loading…
Reference in a new issue