Jump to content

Template:Testcase/testcases

From Wikipedia, the free encyclopedia

Test 1: Default settings

[edit]
  • Title bar: defaults to 1st unnamed parameter
  • Layout: defaults to "vertical"

Test 1: Code

[edit]
{{testcase
|{{WPHawaii|category=no|class=NA}}
|{{WPHawaii|category=no|class=NA}}
|{{WPHawaii/sandbox|category=no|class=NA}}
}}

Test 1: Output of live template

[edit]
{{WPHawaii|category=no|class=NA}}
{{WPHawaii|category=no|class=NA}}
WikiProject iconHawaii Unassessed
WikiProject iconThis article is within the scope of WikiProject Hawaii, a collaborative effort to improve the coverage of Hawaii on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
???This article has not yet received a rating on Wikipedia's content assessment scale.
???This article has not yet received a rating on the project's importance scale.
WikiProject iconHawaii Unassessed
WikiProject iconThis article is within the scope of WikiProject Hawaii, a collaborative effort to improve the coverage of Hawaii on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
???This article has not yet received a rating on Wikipedia's content assessment scale.
???This article has not yet received a rating on the project's importance scale.
Expanded code
'"`UNIQ--templatestyles-00000008-QINU`"''"`UNIQ--templatestyles-0000000A-QINU`"'<table class="tmbox tmbox-notice mw-collapsible innercollapse wpb wpb-table"><tr class="wpb-header"><td class="wpb-header-icon">[[File:Flag of Hawaii.svg|35x25px|alt=WikiProject icon]]</td><td class="wpb-header-combined">[[Wikipedia:WikiProject Hawaii|Hawaii]] <span class="wpb-header-bubbles class-unassessed">Unassessed</span></td></tr><tr><td class="mbox-text wpb-main" colspan="2"><table><tr><td class="mbox-image wpb-image">[[File:Flag of Hawaii.svg|80px|alt=WikiProject icon]]</td><td class="mbox-text">'"`UNIQ--templatestyles-00000006-QINU`"'<ul role="navigation" aria-label="Portals" class="noprint portalbox portalborder portalright"> <li class="portalbox-entry"><span class="portalbox-image">[[File:Flag of Hawaii.svg|border|link=|alt=flag|32x28px|class=noviewer]]</span><span class="portalbox-link">[[Portal:Hawaii|Hawaii portal]]</span></li></ul>This article is within the scope of <b>[[Wikipedia:WikiProject Hawaii|WikiProject Hawaii]]</b>, a collaborative effort to improve the coverage of [[Hawaii]] on Wikipedia. If you would like to participate, please visit the project page, where you can join [[Wikipedia talk:WikiProject Hawaii|the discussion]] and see a list of open tasks.<span class="metadata wpb-metadata"><span class="wpb-project">Hawaii</span><span class="wpb-project_link">Wikipedia:WikiProject Hawaii</span><span class="wpb-banner_name">Template:WikiProject Hawaii</span><span class="wpb-assessment_cat">Hawaii articles</span></span></td><td class="mbox-empty-cell"></td></tr><tr><td class="assess class-unassessed">[[:Category:Unassessed Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on Wikipedia's [[Wikipedia:Content assessment|content assessment]] scale.</td></tr><tr><td class="assess import-unknown">[[:Category:Unknown-importance Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on the [[Wikipedia:WikiProject Hawaii/Assessment#Importance scale|project's importance scale]].</td></tr></table></td></tr></table>
'"`UNIQ--templatestyles-0000000D-QINU`"''"`UNIQ--templatestyles-0000000E-QINU`"'<table class="tmbox tmbox-notice mw-collapsible innercollapse wpb wpb-table"><tr class="wpb-header"><td class="wpb-header-icon">[[File:Flag of Hawaii.svg|35x25px|alt=WikiProject icon]]</td><td class="wpb-header-combined">[[Wikipedia:WikiProject Hawaii|Hawaii]] <span class="wpb-header-bubbles class-unassessed">Unassessed</span></td></tr><tr><td class="mbox-text wpb-main" colspan="2"><table><tr><td class="mbox-image wpb-image">[[File:Flag of Hawaii.svg|80px|alt=WikiProject icon]]</td><td class="mbox-text">'"`UNIQ--templatestyles-0000000C-QINU`"'<ul role="navigation" aria-label="Portals" class="noprint portalbox portalborder portalright"> <li class="portalbox-entry"><span class="portalbox-image">[[File:Flag of Hawaii.svg|border|link=|alt=flag|32x28px|class=noviewer]]</span><span class="portalbox-link">[[Portal:Hawaii|Hawaii portal]]</span></li></ul>This article is within the scope of <b>[[Wikipedia:WikiProject Hawaii|WikiProject Hawaii]]</b>, a collaborative effort to improve the coverage of [[Hawaii]] on Wikipedia. If you would like to participate, please visit the project page, where you can join [[Wikipedia talk:WikiProject Hawaii|the discussion]] and see a list of open tasks.<span class="metadata wpb-metadata"><span class="wpb-project">Hawaii</span><span class="wpb-project_link">Wikipedia:WikiProject Hawaii</span><span class="wpb-banner_name">Template:WikiProject Hawaii</span><span class="wpb-assessment_cat">Hawaii articles</span></span></td><td class="mbox-empty-cell"></td></tr><tr><td class="assess class-unassessed">[[:Category:Unassessed Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on Wikipedia's [[Wikipedia:Content assessment|content assessment]] scale.</td></tr><tr><td class="assess import-unknown">[[:Category:Unknown-importance Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on the [[Wikipedia:WikiProject Hawaii/Assessment#Importance scale|project's importance scale]].</td></tr></table></td></tr></table>

Test 1: Output of sandbox template

[edit]
{{WPHawaii|category=no|class=NA}}
<includeonly></includeonly> style="background:none; border:none; padding:0; margin:0; white-space: pre-wrap; word-wrap: break-word;">{{{1}}}
WikiProject iconHawaii Unassessed
WikiProject iconThis article is within the scope of WikiProject Hawaii, a collaborative effort to improve the coverage of Hawaii on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
???This article has not yet received a rating on Wikipedia's content assessment scale.
???This article has not yet received a rating on the project's importance scale.
WikiProject iconHawaii Unassessed
WikiProject iconThis article is within the scope of WikiProject Hawaii, a collaborative effort to improve the coverage of Hawaii on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
???This article has not yet received a rating on Wikipedia's content assessment scale.
???This article has not yet received a rating on the project's importance scale.
Expanded code
'"`UNIQ--templatestyles-00000013-QINU`"''"`UNIQ--templatestyles-00000014-QINU`"'<table class="tmbox tmbox-notice mw-collapsible innercollapse wpb wpb-table"><tr class="wpb-header"><td class="wpb-header-icon">[[File:Flag of Hawaii.svg|35x25px|alt=WikiProject icon]]</td><td class="wpb-header-combined">[[Wikipedia:WikiProject Hawaii|Hawaii]] <span class="wpb-header-bubbles class-unassessed">Unassessed</span></td></tr><tr><td class="mbox-text wpb-main" colspan="2"><table><tr><td class="mbox-image wpb-image">[[File:Flag of Hawaii.svg|80px|alt=WikiProject icon]]</td><td class="mbox-text">'"`UNIQ--templatestyles-00000012-QINU`"'<ul role="navigation" aria-label="Portals" class="noprint portalbox portalborder portalright"> <li class="portalbox-entry"><span class="portalbox-image">[[File:Flag of Hawaii.svg|border|link=|alt=flag|32x28px|class=noviewer]]</span><span class="portalbox-link">[[Portal:Hawaii|Hawaii portal]]</span></li></ul>This article is within the scope of <b>[[Wikipedia:WikiProject Hawaii|WikiProject Hawaii]]</b>, a collaborative effort to improve the coverage of [[Hawaii]] on Wikipedia. If you would like to participate, please visit the project page, where you can join [[Wikipedia talk:WikiProject Hawaii|the discussion]] and see a list of open tasks.<span class="metadata wpb-metadata"><span class="wpb-project">Hawaii</span><span class="wpb-project_link">Wikipedia:WikiProject Hawaii</span><span class="wpb-banner_name">Template:WikiProject Hawaii</span><span class="wpb-assessment_cat">Hawaii articles</span></span></td><td class="mbox-empty-cell"></td></tr><tr><td class="assess class-unassessed">[[:Category:Unassessed Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on Wikipedia's [[Wikipedia:Content assessment|content assessment]] scale.</td></tr><tr><td class="assess import-unknown">[[:Category:Unknown-importance Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on the [[Wikipedia:WikiProject Hawaii/Assessment#Importance scale|project's importance scale]].</td></tr></table></td></tr></table>
'"`UNIQ--templatestyles-00000016-QINU`"''"`UNIQ--templatestyles-00000017-QINU`"'<table class="tmbox tmbox-notice mw-collapsible innercollapse wpb wpb-table"><tr class="wpb-header"><td class="wpb-header-icon">[[File:Flag of Hawaii.svg|35x25px|alt=WikiProject icon]]</td><td class="wpb-header-combined">[[Wikipedia:WikiProject Hawaii|Hawaii]] <span class="wpb-header-bubbles class-unassessed">Unassessed</span></td></tr><tr><td class="mbox-text wpb-main" colspan="2"><table><tr><td class="mbox-image wpb-image">[[File:Flag of Hawaii.svg|80px|alt=WikiProject icon]]</td><td class="mbox-text">'"`UNIQ--templatestyles-00000015-QINU`"'<ul role="navigation" aria-label="Portals" class="noprint portalbox portalborder portalright"> <li class="portalbox-entry"><span class="portalbox-image">[[File:Flag of Hawaii.svg|border|link=|alt=flag|32x28px|class=noviewer]]</span><span class="portalbox-link">[[Portal:Hawaii|Hawaii portal]]</span></li></ul>This article is within the scope of <b>[[Wikipedia:WikiProject Hawaii|WikiProject Hawaii]]</b>, a collaborative effort to improve the coverage of [[Hawaii]] on Wikipedia. If you would like to participate, please visit the project page, where you can join [[Wikipedia talk:WikiProject Hawaii|the discussion]] and see a list of open tasks.<span class="metadata wpb-metadata"><span class="wpb-project">Hawaii</span><span class="wpb-project_link">Wikipedia:WikiProject Hawaii</span><span class="wpb-banner_name">Template:WikiProject Hawaii</span><span class="wpb-assessment_cat">Hawaii articles</span></span></td><td class="mbox-empty-cell"></td></tr><tr><td class="assess class-unassessed">[[:Category:Unassessed Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on Wikipedia's [[Wikipedia:Content assessment|content assessment]] scale.</td></tr><tr><td class="assess import-unknown">[[:Category:Unknown-importance Hawaii articles|???]]</td><td class="mbox-text" colspan="2">This article has not yet received a rating on the [[Wikipedia:WikiProject Hawaii/Assessment#Importance scale|project's importance scale]].</td></tr></table></td></tr></table>

Test 2: Non-default settings

[edit]
  • Title bar: specified via the id parameter
  • Layout: specified via the layout parameter

Test 2: Code

[edit]
{{Testcase | id=Nirvana | layout=horizontal
|<!--display template code-->
{{Infobox album
| Name        = Nirvana
| Type        = greatest
| Artist      = [[Nirvana (band)|Nirvana]]
| Released    = October 29, 2002
| Recorded    = 1988–1994
| Genre       = [[Grunge music|Grunge]]
| Length      = 49:38
| Language    = [[English language|English]]
| Label       = [[DGC Records|DGC]]
| Producer    = [[Steve Albini]], [[Jack Endino]], [[Steve Fisk]], [[Scott Litt]], [[Butch Vig]]
<!--| Reviews     = *[[Allmusic]] {{Rating|2.5|5}}-->
| Last album  = ''[[From the Muddy Banks of the Wishkah]]''<br />(1996)
| This album  = '''''Nirvana''''' <br /> (2002)
| Next album  = ''[[With the Lights Out]]''<br />(2004)
}}
| <!--display output of live template-->
{{Infobox album
| Name        = Nirvana
| Type        = greatest
| Artist      = [[Nirvana (band)|Nirvana]]
| Released    = October 29, 2002
| Recorded    = 1988–1994
| Genre       = [[Grunge music|Grunge]]
| Length      = 49:38
| Language    = [[English language|English]]
| Label       = [[DGC Records|DGC]]
| Producer    = [[Steve Albini]], [[Jack Endino]], [[Steve Fisk]], [[Scott Litt]], [[Butch Vig]]
<!--| Reviews     = *[[Allmusic]] {{Rating|2.5|5}}-->
| Last album  = ''[[From the Muddy Banks of the Wishkah]]''<br />(1996)
| This album  = '''''Nirvana''''' <br /> (2002)
| Next album  = ''[[With the Lights Out]]''<br />(2004)
}}
| <!--display output of sandbox template-->
{{Infobox album/sandbox
| Name        = Nirvana
| Type        = greatest
| Artist      = [[Nirvana (band)|Nirvana]]
| Released    = October 29, 2002
| Recorded    = 1988–1994
| Genre       = [[Grunge music|Grunge]]
| Length      = 49:38
| Language    = [[English language|English]]
| Label       = [[DGC Records|DGC]]
| Producer    = [[Steve Albini]], [[Jack Endino]], [[Steve Fisk]], [[Scott Litt]], [[Butch Vig]]
<!--| Reviews     = *[[Allmusic]] {{Rating|2.5|5}}-->
| Last album  = ''[[From the Muddy Banks of the Wishkah]]''<br />(1996)
| This album  = '''''Nirvana''''' <br /> (2002)
| Next album  = ''[[With the Lights Out]]''<br />(2004)
}}
}} <!--end of {{Testcase}}-->

Test 2: Output of live template

[edit]
Nirvana
{{Infobox album
| Name        = Nirvana
| Type        = greatest
| Artist      = [[Nirvana (band)|Nirvana]]
| Released    = October 29, 2002
| Recorded    = 1988–1994
| Genre       = [[Grunge music|Grunge]]
| Length      = 49:38
| Language    = [[English language|English]]
| Label       = [[DGC Records|DGC]]
| Producer    = [[Steve Albini]], [[Jack Endino]], [[Steve Fisk]], [[Scott Litt]], [[Butch Vig]]
<!--| Reviews     = *[[Allmusic]] {{Rating|2.5|5}}-->
| Last album  = ''[[From the Muddy Banks of the Wishkah]]''<br />(1996)
| This album  = '''''Nirvana''''' <br /> (2002)
| Next album  = ''[[With the Lights Out]]''<br />(2004)
}}
Untitled


Untitled
Expanded code
'"`UNIQ--templatestyles-0000001D-QINU`"'<table class="infobox vevent haudio"><tr><th colspan="2" class="infobox-above summary album" style="font-style: italic; color: inherit; background-color: peachpuff; font-size: 125%;"><span style="font-style: normal">Untitled</span></th></tr></table>
'"`UNIQ--templatestyles-0000001F-QINU`"'<table class="infobox vevent haudio"><tr><th colspan="2" class="infobox-above summary album" style="font-style: italic; color: inherit; background-color: peachpuff; font-size: 125%;"><span style="font-style: normal">Untitled</span></th></tr></table>

Test 2: Output of sandbox template

[edit]
Nirvana
<includeonly></includeonly> style="background:none; border:none; padding:0; margin:0; white-space: pre-wrap; word-wrap: break-word;">{{{1}}}
Untitled


Untitled
Expanded code
'"`UNIQ--templatestyles-00000023-QINU`"'<table class="infobox vevent haudio"><tr><th colspan="2" class="infobox-above summary album" style="font-style: italic; color: inherit; background-color: peachpuff; font-size: 125%;"><span style="font-style: normal">Untitled</span></th></tr></table>
'"`UNIQ--templatestyles-00000024-QINU`"'<table class="infobox vevent haudio"><tr><th colspan="2" class="infobox-above summary album" style="font-style: italic; color: inherit; background-color: peachpuff; font-size: 125%;"><span style="font-style: normal">Untitled</span></th></tr></table>