72 lines
2.0 KiB
JSON
72 lines
2.0 KiB
JSON
{
|
|
"description": "Test `Special:Ask` output for `_txt` with formatted text (#..., `wgContLang=en`, `wgLang=en`)",
|
|
"setup": [
|
|
{
|
|
"namespace": "SMW_NS_PROPERTY",
|
|
"page": "Has text",
|
|
"contents": "[[Has type::Text]]"
|
|
},
|
|
{
|
|
"namespace": "NS_MAIN",
|
|
"page": "Example/SA0004/1",
|
|
"contents": "[[Has text::Test '''with text formatting''']] {{#set: Has text=Link to [[Example/SA0004/1]]}} [[Category:SA0004]]"
|
|
},
|
|
{
|
|
"namespace": "NS_MAIN",
|
|
"page": "Example/SA0004/2",
|
|
"contents": "[[Code::Test '''with text formatting''']] {{#set: Code=Link to [[Example/SA0004/1]]}} [[Category:SA0004]]"
|
|
}
|
|
],
|
|
"tests": [
|
|
{
|
|
"type": "special",
|
|
"about": "#0 (`_txt` formatting, link)",
|
|
"special-page": {
|
|
"page": "Ask",
|
|
"query-parameters": "-5B-5BCategory:SA0004-5D-5D-20-5B-5BHas text%3A%3A%2B-5D-5D/-3FHas text/mainlabel=-/offset=0/format=broadtable/link=all/headers=show",
|
|
"request-parameters": []
|
|
},
|
|
"assert-output": {
|
|
"to-contain": [
|
|
"Test <b>with text formatting</b>",
|
|
"Link to <a",
|
|
"Example/SA0004/1\" title=\"Example/SA0004/1\">Example/SA0004/1</a>"
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"type": "special",
|
|
"about": "#1 (`_cod` formatting, link)",
|
|
"special-page": {
|
|
"page": "Ask",
|
|
"query-parameters": "-5B-5BCategory%3ASA0004-5D-5D-20-5B-5BCode%3A%3A%2B-5D-5D/-3FCode/mainlabel=-/offset=0/format=broadtable/link=all/headers=show",
|
|
"request-parameters": []
|
|
},
|
|
"assert-output": {
|
|
"to-contain": [
|
|
"<div class=\"smwpre\">Link to [[Example/SA0004/1]]</div>",
|
|
"<div class=\"smwpre\">Test '''with text formatting'''</div>"
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"settings": {
|
|
"wgContLang": "en",
|
|
"wgLang": "en",
|
|
"wgLanguageCode": "en",
|
|
"smwgNamespace": "http://example.org/id/",
|
|
"smwgPageSpecialProperties": [
|
|
"_MDAT"
|
|
],
|
|
"smwgNamespacesWithSemanticLinks": {
|
|
"NS_MAIN": true,
|
|
"SMW_NS_PROPERTY": true
|
|
}
|
|
},
|
|
"meta": {
|
|
"version": "2",
|
|
"is-incomplete": false,
|
|
"debug": false
|
|
}
|
|
}
|