Difference between revisions of "Template:Linked/testcases"
imported>Andrybak (create testcases using examples from Template:Linked/doc) |
imported>Andrybak m (formatting) |
||
| Line 2: | Line 2: | ||
== Wikilinks == | == Wikilinks == | ||
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|Foo}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|Foo|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|[[Foo]]|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|:Foo}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|File:Example.jpg}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|:File:Example.jpg}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|Category:Food}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|:Category:Food}} |
== HTTP links == | == HTTP links == | ||
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes| http://example.org}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|http://example.org|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|[http://example.org Foo]|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|https://example.org}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|https://example.org|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|[https://example.org Foo]|Bar}} |
== Protocol-relative // links == | == Protocol-relative // links == | ||
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|//example.org}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|//example.org|Bar}} |
| − | {{Test case|_collapsible=yes|_showcode=yes| | + | {{Test case|_collapsible=yes|_showcode=yes|_titlecode=yes|[//example.org Foo]|Bar}} |
Revision as of 17:46, 27 May 2020
| 42px | This is the template test cases page for the sandbox of Template:Linked. Script error: No such module "Purge". to update the examples. If there are many examples of a complicated template, later ones may break due to limits in MediaWiki, see the HTML comment "NewPP limit report" in the rendered page. You can also use Special:ExpandTemplates to examine the results of template uses. You can test how this page looks in the different skins with these links: |
Wikilinks
| {{Linked|Foo}} |
|---|
{{Linked|Foo}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|Foo|Bar}} |
|---|
{{Linked|Foo|Bar}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|[[Foo]]|Bar}} |
|---|
{{Linked|[[Foo]]|Bar}}
{{Linked}} [[:Template:Str crop]] {{Linked/sandbox}} [[:Template:Str crop]] |
| {{Linked|:Foo}} |
|---|
{{Linked|:Foo}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|File:Example.jpg}} |
|---|
{{Linked|File:Example.jpg}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|:File:Example.jpg}} |
|---|
{{Linked|:File:Example.jpg}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|Category:Food}} |
|---|
{{Linked|Category:Food}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|:Category:Food}} |
|---|
{{Linked|:Category:Food}}
{{Linked}} {{Linked/sandbox}} |
HTTP links
| {{Linked| http://example.org}} |
|---|
{{Linked| http://example.org}}
{{Linked}} [[[:Template:Str trim]]] {{Linked/sandbox}} [[[:Template:Str trim]]] |
| {{Linked|http://example.org|Bar}} |
|---|
{{Linked|http://example.org|Bar}}
{{Linked}} [[[:Template:Str trim]] Bar] {{Linked/sandbox}} [[[:Template:Str trim]] Bar] |
| {{Linked|[http://example.org Foo]|Bar}} |
|---|
{{Linked|[http://example.org Foo]|Bar}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|https://example.org}} |
|---|
{{Linked|https://example.org}}
{{Linked}} [[[:Template:Str trim]]] {{Linked/sandbox}} [[[:Template:Str trim]]] |
| {{Linked|https://example.org|Bar}} |
|---|
{{Linked|https://example.org|Bar}}
{{Linked}} [[[:Template:Str trim]] Bar] {{Linked/sandbox}} [[[:Template:Str trim]] Bar] |
| {{Linked|[https://example.org Foo]|Bar}} |
|---|
{{Linked|[https://example.org Foo]|Bar}}
{{Linked}} {{Linked/sandbox}} |
Protocol-relative // links
| {{Linked|//example.org}} |
|---|
{{Linked|//example.org}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|//example.org|Bar}} |
|---|
{{Linked|//example.org|Bar}}
{{Linked}} {{Linked/sandbox}} |
| {{Linked|[//example.org Foo]|Bar}} |
|---|
{{Linked|[//example.org Foo]|Bar}}
{{Linked}} {{Linked/sandbox}} |