From bc3e0c08c2594c7eefdfa8fed51caa5632f23a5a Mon Sep 17 00:00:00 2001 From: Subramanya Sastry Date: Wed, 26 Sep 2012 13:58:30 -0500 Subject: [PATCH] New tests to check handling of tpl-name and tplarg-name clashes. Change-Id: I99180af6460b8925a64b751650aaae6163e4ac27 --- tests/parser/parserTests.txt | 38 ++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt index fea9296e6b..b3b9262a92 100644 --- a/tests/parser/parserTests.txt +++ b/tests/parser/parserTests.txt @@ -4119,6 +4119,44 @@ section=1 ==Section 1== !! end +### +### Testing parsing of templates where a template arg +### has the same name as the template itself. +### + +!! article +Template:quote +!! text +{{{quote|{{{1}}} }}} +!! endarticle + +!!test +Templates: Template Name/Arg clash: 1. Use of positional param +!!input +{{quote|foo}} +!!result +

foo +

+!!end + +!!test +Templates: Template Name/Arg clash: 2. Use of named param +!!input +{{quote|quote=foo}} +!!result +

foo +

+!!end + +!!test +Templates: Template Name/Arg clash: 3. Use of named param with empty input +!!input +{{quote|quote}} +!!result +

quote +

+!!end + ### ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged ### -- 2.20.1