3 * Parser-related tests that don't suit for parserTests.txt
6 class ExtraParserTest
extends PHPUnit_Framework_TestCase
{
11 global $wgShowDBErrorBacktrace;
13 $wgShowDBErrorBacktrace = true;
14 if ( $wgContLang === null ) $wgContLang = new Language
;
15 $wgMemc = new FakeMemCachedClient
;
18 // Bug 8689 - Long numeric lines kill the parser
19 function testBug8689() {
22 $longLine = '1.' . str_repeat( '1234567890', 100000 ) . "\n";
24 if ( $wgLang === null ) $wgLang = new Language
;
25 $parser = new Parser();
26 $t = Title
::newFromText( 'Unit test' );
27 $options = ParserOptions
::newFromUser( $wgUser );
28 $this->assertEquals( "<p>$longLine</p>",
29 $parser->parse( $longLine, $t, $options )->getText() );