Another couple of tests. Also passed by the NtPrepro :)
authorPlatonides <platonides@users.mediawiki.org>
Sun, 16 Jan 2011 18:20:44 +0000 (18:20 +0000)
committerPlatonides <platonides@users.mediawiki.org>
Sun, 16 Jan 2011 18:20:44 +0000 (18:20 +0000)
tests/phpunit/includes/parser/PreprocessorTest.php

index 0b191ca..b001453 100644 (file)
@@ -66,6 +66,8 @@ class PreprocessorTest extends MediaWikiTestCase {
                        array( "{{{{{{Foo}}}}}}", "<root><tplarg><title><tplarg><title>Foo</title></tplarg></title></tplarg></root>" ),
                        array( "{{{{{{Foo}}}}}", "<root>{<template><title><tplarg><title>Foo</title></tplarg></title></template></root>" ),
                        array( "[[[Foo]]", "<root>[[[Foo]]</root>" ),
+                       array( "{{Foo|[[[[bar]]|baz]]}}", "<root><template><title>Foo</title><part><name index=\"1\" /><value>[[[[bar]]|baz]]</value></part></template></root>" ), /* This test is important, since it means the difference between having the [[ rule stacked or not */
+                       array( "{{Foo|[[[[bar]|baz]]}}", "<root>{{Foo|[[[[bar]|baz]]}}</root>" ),
                        /* array( file_get_contents( dirname( __FILE__ ) . '/QuoteQuran.txt' ), file_get_contents( dirname( __FILE__ ) . '/QuoteQuranExpanded.txt' ) ), */
                );
        }