summaryrefslogtreecommitdiff
path: root/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/r-0008.json
blob: 2d32b97d8610283ff7dcbccb0b4d295c30c6b709 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
{
	"description": "Test RDF output generation on pages that contain incoming error annotations (`wgContLang=en`, `wgLang=es`, syntax=rdf/turtle)",
	"setup": [
		{
			"namespace": "SMW_NS_PROPERTY",
			"page": "Has area without unit",
			"contents": "[[Has type::Quantity]]"
		},
		{
			"page": "Example/R0008/1",
			"contents": "[[Has area without unit::1 m]]"
		}
	],
	"tests": [
		{
			"type": "rdf",
			"about": "#0 incoming (error) is exported in canonical form (especially when user language is different)",
			"exportcontroller": {
				"print-pages": [
					"Property:Has area without unit"
				],
				"parameters": {
					"backlinks": true,
					"recursion": "1",
					"revisiondate": false
				}
			},
			"assert-output": {
				"to-contain": [
					"<owl:DatatypeProperty rdf:about=\"http://example.org/id/Property-3AHas_area_without_unit\">",
					"<rdfs:label>Has area without unit</rdfs:label>",
					"<swivt:wikiPageSortKey rdf:datatype=\"http://www.w3.org/2001/XMLSchema#string\">Has area without unit</swivt:wikiPageSortKey>",
					"<swivt:type rdf:resource=\"http://semantic-mediawiki.org/swivt/1.0#_qty\"/>"
				],
				"not-contain": [
					"<owl:ObjectProperty rdf:about=\"http://example.org/id/Property-3ATiene_valor_incorrecto_para\">",
					"<swivt:wikiPageSortKey rdf:datatype=\"http://www.w3.org/2001/XMLSchema#string\">Tiene valor incorrecto para</swivt:wikiPageSortKey>"
				]
			}
		},
		{
			"type": "rdf",
			"about": "#1 (turtle)",
			"exportcontroller": {
				"syntax": "turtle",
				"print-pages": [
					"Property:Has area without unit"
				],
				"parameters": {
					"backlinks": true,
					"recursion": "1",
					"revisiondate": false
				}
			},
			"assert-output": {
				"to-contain": [
					"property:Has_area_without_unit",
					"rdf:type  owl:DatatypeProperty ;",
					"rdfs:label  \"Has area without unit\" ;",
					"swivt:wikiNamespace  \"102\"^^xsd:integer ;",
					"swivt:wikiPageSortKey  \"Has area without unit\" ;",
					"swivt:type  <http://semantic-mediawiki.org/swivt/1.0#_qty> .",
					"<http://example.org/id/Example/R0008/1-23_ERR3b4d92de525df0eeb65e83ea06e2a5d4>",
					"swivt:masterPage  <http://example.org/id/Example/R0008/1> ;",
					"property:Has_improper_value_for  property:Has_area_without_unit ;"
				]
			}
		}
	],
	"settings": {
		"smwgExportBCNonCanonicalFormUse": false,
		"smwgNamespacesWithSemanticLinks": {
			"NS_MAIN": true,
			"NS_CATEGORY": true,
			"SMW_NS_PROPERTY": true
		},
		"wgContLang": "en",
		"wgLang": "es",
		"smwgNamespace": "http://example.org/id/"
	},
	"meta": {
		"version": "2",
		"is-incomplete": false,
		"debug": false
	}
}