Skip to content

Commit

Permalink
Added test for #47
Browse files Browse the repository at this point in the history
  • Loading branch information
gesinn-it-wam committed Mar 1, 2023
1 parent c06b6d1 commit c517061
Showing 1 changed file with 44 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,22 +1,38 @@
{
"description": "display parameters",
"setup": [
{
"namespace": "SMW_NS_PROPERTY",
"page": "Text",
"contents": "[[Has type::Text]]"
},
{
"namespace": "NS_CATEGORY",
"page": "Category1",
"page": "WithCaption",
"contents": "{{#drilldowninfo: display parameters=caption=THIS IS THE CAPTION}}"
},
{
"namespace": "NS_CATEGORY",
"page": "WithMainColumn",
"contents": "{{#drilldowninfo: display parameters=format=plainlist;headers=hide;?Text}}"
},
{
"namespace": "NS_CATEGORY",
"page": "WithoutMainColumn",
"contents": "{{#drilldowninfo: display parameters=format=plainlist;headers=hide;?Text;mainlabel=-}}"
},
{
"page": "Page1",
"contents": "[[Category:Category1]]"
} ],
"contents": "[[Category:WithCaption]] [[Category:WithMainColumn]] [[Category:WithoutMainColumn]] [[Text::MARKER TEXT]]"
}
],
"tests": [
{
"type": "special",
"about": "Caption and results are wrapped in corresponding divs",
"special-page": {
"page": "BrowseData",
"query-parameters": "Category1",
"query-parameters": "WithCaption",
"request-parameters": {}
},
"assert-output": {
Expand All @@ -26,6 +42,30 @@
"<div class=\"drilldown-result-body\">"
]
}
},
{
"type": "special",
"about": "The main column as shown by default",
"special-page": {
"page": "BrowseData",
"query-parameters": "WithMainColumn",
"request-parameters": {}
},
"assert-output": {
"to-contain": "<p><a href=\"/index.php/Page1\" title=\"Page1\">Page1</a> (MARKER TEXT)"
}
},
{
"type": "special",
"about": "The main column as removed with mainlabel=- as expected",
"special-page": {
"page": "BrowseData",
"query-parameters": "WithoutMainColumn",
"request-parameters": {}
},
"assert-output": {
"to-contain": "<p>MARKER TEXT"
}
}
],
"settings": {
Expand Down

0 comments on commit c517061

Please sign in to comment.