summaryrefslogtreecommitdiff
path: root/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0902.json
blob: 0d0c7be7b7bffbf84e356cd5b15622d4f501b577 (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
{
	"description": "Test `_txt` to correctly apply parentheses for somehting like (a OR b OR c) AND d (#556)",
	"setup": [
		{
			"namespace": "SMW_NS_PROPERTY",
			"page": "Has conference type",
			"contents": "[[Has type::Text]]"
		},
		{
			"page": "Conference-1",
			"contents": "[[Has conference type::Presentation]], [[Has conference type::Tutorial]]"
		},
		{
			"page": "Conference-2",
			"contents": "[[Has conference type::Tutorial]]"
		}
	],
	"tests": [
		{
			"type": "query",
			"about": "#0",
			"condition": "[[Conference-1]] [[Has conference type::Presentation||Tutorial]]",
			"printouts": [],
			"parameters": {
				"limit": "10"
			},
			"assert-queryresult": {
				"results": [
					"Conference-1#0##"
				],
				"count": "1",
				"dataitems": []
			}
		},
		{
			"type": "query",
			"about": "#1",
			"condition": "<q>[[Conference-1]] [[Has conference type::Presentation||Tutorial||Another]]</q> OR [[Has conference type::Presentation||Tutorial||Another]]",
			"printouts": [],
			"parameters": {
				"limit": "10"
			},
			"assert-queryresult": {
				"results": [
					"Conference-1#0##",
					"Conference-2#0##"
				],
				"count": "2",
				"dataitems": []
			}
		}
	],
	"settings": {
		"smwgNamespacesWithSemanticLinks": {
			"NS_MAIN": true,
			"NS_HELP": true,
			"SMW_NS_PROPERTY": true
		}
	},
	"meta": {
		"version": "2",
		"is-incomplete": false,
		"debug": false
	}
}