Difference between revisions of "Template:Main/testcases"

From blackwiki
Jump to navigation Jump to search
imported>MSGJ
m (MSGJ moved page Template:Main/testcases to Template:Main article/testcases: more descriptive name for template, no objections on talk page)
imported>Andrybak
m (add whitespace for readability)
 
(6 intermediate revisions by 5 users not shown)
Line 1: Line 1:
 
{{test cases}}
 
{{test cases}}
  
== Test main ==
+
The first output example in each pair is the main template, and second is the sandbox.
  
* <code><nowiki>{{Main|John}}</nowiki></code>
+
== Parameter category ==
{{Main|John}}
+
{{test case|_format=inline|_showcode=yes|category=false}}
  
* <code><nowiki>{{Main|John|George}}</nowiki></code>
+
== Positional parameters ==
{{Main|John|George}}
+
{{test case|_format=inline|_showcode=yes|John}}
  
* <code><nowiki>{{Main|John|George|Ringo}}</nowiki></code>
+
{{test case|_format=inline|_showcode=yes|John|George}}
{{Main|John|George|Ringo}}
 
  
* <code><nowiki>{{Main|:Category:John}}</nowiki></code>
+
{{test case|_format=inline|_showcode=yes|John|George|Ringo}}
{{Main|:Category:John}}
 
  
* <code><nowiki>{{Main|Template:John|George}}</nowiki></code>
+
=== Other namespaces links ===
{{Main|Template:John|George}}
+
{{test case|_format=inline|_showcode=yes|:Category:John}}
  
* <code><nowiki>{{Main|Talk:John|George|Ringo}}</nowiki></code>
+
{{test case|_format=inline|_showcode=yes|Template:John|George}}
{{Main|Talk:John|George|Ringo}}
 
  
* <code><nowiki>{{Main|History of the United States|RMS Titanic|WindSeeker|l2=RMS ''Titanic''}}</nowiki></code>
+
{{test case|_format=inline|_showcode=yes|Talk:John|George|Ringo}}
{{Main|History of the United States|RMS Titanic|WindSeeker|l2=RMS ''Titanic''}}
 
  
* <code><nowiki>{{Main|Lion#Etymology}}</nowiki></code>
+
=== With anchor links ===
{{Main|Lion#Etymology}}
+
{{test case|_format=inline|_showcode=yes|Lion#Etymology}}
  
* <code><nowiki>{{Main|John|}}</nowiki></code>
+
=== Missing positional parameter ===
{{Main|John|}}
+
{{test case|_format=inline|_showcode=yes|John|}}
  
== Test sandbox ==
+
== Parameter l2 ==
 
+
{{test case|_format=inline|_showcode=yes|History of the United States|RMS Titanic|WindSeeker|l2=RMS ''Titanic''}}
* <code><nowiki>{{Main/sandbox|John}}</nowiki></code>
 
{{Main/sandbox|John}}
 
 
 
* <code><nowiki>{{Main/sandbox|John|George}}</nowiki></code>
 
{{Main/sandbox|John|George}}
 
 
 
* <code><nowiki>{{Main/sandbox|John|George|Ringo}}</nowiki></code>
 
{{Main/sandbox|John|George|Ringo}}
 
 
 
* <code><nowiki>{{Main/sandbox|:Category:John}}</nowiki></code>
 
{{Main/sandbox|:Category:John}}
 
 
 
* <code><nowiki>{{Main/sandbox|Template:John|George}}</nowiki></code>
 
{{Main/sandbox|Template:John|George}}
 
 
 
* <code><nowiki>{{Main/sandbox|Talk:John|George|Ringo}}</nowiki></code>
 
{{Main/sandbox|Talk:John|George|Ringo}}
 
 
 
* <code><nowiki>{{Main/sandbox|History of the United States|RMS Titanic|WindSeeker|l2=RMS ''Titanic''}}</nowiki></code>
 
{{Main/sandbox|History of the United States|RMS Titanic|WindSeeker|l2=RMS ''Titanic''}}
 
 
 
* <code><nowiki>{{Main/sandbox|Lion#Etymology}}</nowiki></code>
 
{{Main/sandbox|Lion#Etymology}}
 
 
 
* <code><nowiki>{{Main/sandbox|John|}}</nowiki></code>
 
{{Main/sandbox|John|}}
 

Latest revision as of 22:04, 8 May 2020

Template:Test cases

The first output example in each pair is the main template, and second is the sandbox.

Parameter category

Positional parameters

  • {{Main|John}}
  • {{Main/sandbox|John}}


  • {{Main|John|George}}
  • {{Main/sandbox|John|George}}


Other namespaces links



With anchor links

Missing positional parameter

  • {{Main|John|}}
  • {{Main/sandbox|John|}}

Parameter l2