Sanitize filesystem paths before emitting ParserTests.data.

Change-Id: Ic348aa040d3b0e64716a51f5681ef289842118f0
This commit is contained in:
C. Scott Ananian 2014-07-24 17:53:28 -04:00
parent 247314382f
commit 5cc82325c2

View file

@ -83,6 +83,7 @@ class MathGenerateTests extends Maintenance
$i = 0;
foreach ( array_slice( $allEquations, $offset, $length, true ) as $input ) {
$output = MathRenderer::renderMath( $input, array(), MW_MATH_PNG );
$output = preg_replace( '#src="(.*?)/(([a-f]|\d)*).png"#', 'src="\2.png"', $output );
$parserTests[] = array( (string)$input, $output );
$i++;
echo '.';