summaryrefslogtreecommitdiff
path: root/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json
diff options
context:
space:
mode:
Diffstat (limited to 'www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json')
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json60
1 files changed, 60 insertions, 0 deletions
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json
new file mode 100644
index 00000000..218ca898
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0406.json
@@ -0,0 +1,60 @@
+{
+ "description": "Test in-text annotation for unrestricted template parse using `import-annotation=true` (#1055)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "HasUnrestrictedPage",
+ "contents": "[[Has type::Page]]"
+ },
+ {
+ "namespace": "NS_TEMPLATE",
+ "page": "CreateAnnotationViaAskTemplate",
+ "contents": "<includeonly>[[HasUnrestrictedPage::{{{1}}}]]</includeonly>"
+ },
+ {
+ "namespace": "NS_TEMPLATE",
+ "page": "TemplateForUnrestrictedParse",
+ "contents": "<includeonly>{{#ask: [[HasUnrestrictedPage::{{{1}}}]]|?HasUnrestrictedPage|link=none|format=template|template=CreateAnnotationViaAskTemplate|import-annotation=true}}</includeonly>"
+ },
+ {
+ "page": "Page-with-annotation",
+ "contents": "[[HasUnrestrictedPage::SearchPageWithAnnotation]]"
+ },
+ {
+ "page": "Page-with-template",
+ "contents": "{{TemplateForUnrestrictedParse|SearchPageWithAnnotation}}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0",
+ "subject": "Page-with-template",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 4,
+ "propertyKeys": [
+ "_SKEY",
+ "HasUnrestrictedPage",
+ "_MDAT",
+ "_ASK"
+ ],
+ "propertyValues": [
+ "Page-with-annotation"
+ ]
+ }
+ }
+ }
+ ],
+ "settings": {
+ "smwgPageSpecialProperties": [
+ "_MDAT"
+ ]
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file