Template:Tn/testcases
From Gentoo Wiki
Jump to:navigation
Jump to:search
Note
This is the template test case page for Template:Tn and its sandbox version. You may have to to update the examples.
This is the template test case page for Template:Tn and its sandbox version. You may have to to update the examples.
Correct
One anonymous parameter: name of a template, whether it exists or not
Wiki code
{{Tn|RootCmd}}
Main version
{{RootCmd}}
Sandbox version
One anonymous parameter containing a pipe character (illustrating a template call with a parameter)
Wiki code
{{Tn|RootCmd{{!}}umount /mnt/gentoo}}
Main version
{{RootCmd|umount /mnt/gentoo}}
Sandbox version
↑ Note that this is OK when using this template, but will not work with the {{Tl}} template.
One anonymous parameter containing a pipe and equals sign (illustrating a template call with named parameter)
Wiki code
{{Tn|RootCmd{{!}}umount /mnt/gentoo{{!}}prompt{{=}}#}}
Main version
{{RootCmd|umount /mnt/gentoo|prompt=#}}
Sandbox version
↑ Note that this will not work when using the {{Tl}} template.
Incorrect
No parameter (error message)
Wiki code
{{Tn}}
Main version
{{Tn template error}}
Parameter 1 not defined. For correct usage see Tn template's documentation on the
1
parameter.Sandbox version
Multiple anonymous parameters (not supported yet)
Wiki code
{{Tn|RootCmd|umount /mnt/gentoo}}
Main version
{{RootCmd}}
Sandbox version