mirror of
https://github.com/github/semantic.git
synced 2024-12-23 23:11:50 +03:00
4620 lines
258 KiB
JSON
4620 lines
258 KiB
JSON
[{
|
|
"testCaseDescription": "javascript-class-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"patch": "insert",
|
|
"range": [
|
|
87,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
87,
|
|
87
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391",
|
|
"8f6ae64dbe49f3d6f2043226aea0eb8148d2751f"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "c0bf9c50b086e8df414580ca552f89fba2c662b5",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "887b77c35fc3859cb39fff72ad9c65d0e311e3bf"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-replacement-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
91,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
104,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
108,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
120,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
113,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
104,
|
|
124
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
126,
|
|
129
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
142,
|
|
143
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
135,
|
|
144
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
126,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
147,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
85,
|
|
172
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
178,
|
|
181
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
191,
|
|
194
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
195,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
207,
|
|
208
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
200,
|
|
209
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
191,
|
|
211
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
213,
|
|
216
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
217,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
229,
|
|
230
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
222,
|
|
231
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
213,
|
|
233
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
234,
|
|
239
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
240,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
252,
|
|
253
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
245,
|
|
254
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
234,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
259
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
87,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
87,
|
|
87
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
259,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
259,
|
|
259
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"8f6ae64dbe49f3d6f2043226aea0eb8148d2751f",
|
|
"b509437fd330d637bc4043a60bfc8202dfe8b258"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "887b77c35fc3859cb39fff72ad9c65d0e311e3bf",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "3711485bf00597407cabae53fe6675a8fc733ed3"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-delete-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
91,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
104,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
108,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
120,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
113,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
104,
|
|
124
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
126,
|
|
129
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
142,
|
|
143
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
135,
|
|
144
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
126,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
147,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
85,
|
|
172
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
96
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
106,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
110,
|
|
111
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
122,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
115,
|
|
124
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
106,
|
|
126
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
128,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
132,
|
|
133
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
145
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
137,
|
|
146
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
128,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
149,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
155,
|
|
156
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
167,
|
|
168
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
160,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
149,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
173
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
174
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
174
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
87,
|
|
174
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
178,
|
|
181
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
191,
|
|
194
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
195,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
207,
|
|
208
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
200,
|
|
209
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
191,
|
|
211
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
213,
|
|
216
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
217,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
229,
|
|
230
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
222,
|
|
231
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
213,
|
|
233
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
234,
|
|
239
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
240,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
252,
|
|
253
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
245,
|
|
254
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
234,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
259
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
180,
|
|
183
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
193,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
197,
|
|
198
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
209,
|
|
210
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
202,
|
|
211
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
193,
|
|
213
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
215,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
219,
|
|
220
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
231,
|
|
232
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
224,
|
|
233
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
215,
|
|
235
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
236,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
242,
|
|
243
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
254,
|
|
255
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
247,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
236,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
260
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
174,
|
|
261
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
259,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
259,
|
|
259
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
261,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
261,
|
|
261
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"b509437fd330d637bc4043a60bfc8202dfe8b258",
|
|
"c4f5c91cec1c4f59df2ae283d70c8194697a777b"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "3711485bf00597407cabae53fe6675a8fc733ed3",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "b55d4fe649118f50cd1aedc1d206791c12f552aa"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-replacement-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
96
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
106,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
110,
|
|
111
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
122,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
115,
|
|
124
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
106,
|
|
126
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
128,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
132,
|
|
133
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
145
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
137,
|
|
146
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
128,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
149,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
155,
|
|
156
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
167,
|
|
168
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
160,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
149,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
173
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
174
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
174
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
87,
|
|
174
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
91,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
104,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
108,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
120,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
113,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
104,
|
|
124
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
126,
|
|
129
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
142,
|
|
143
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
135,
|
|
144
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
126,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
147,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
85,
|
|
172
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
180,
|
|
183
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
193,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
197,
|
|
198
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
209,
|
|
210
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
202,
|
|
211
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
193,
|
|
213
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
215,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
219,
|
|
220
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
231,
|
|
232
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
224,
|
|
233
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
215,
|
|
235
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
236,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
242,
|
|
243
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
254,
|
|
255
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
247,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
236,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
260
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
174,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
174,
|
|
261
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
178,
|
|
181
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
191,
|
|
194
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
195,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
207,
|
|
208
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
200,
|
|
209
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
191,
|
|
211
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
213,
|
|
216
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
217,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
229,
|
|
230
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
222,
|
|
231
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
213,
|
|
233
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
234,
|
|
239
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
240,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
252,
|
|
253
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
245,
|
|
254
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
234,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
259
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
261,
|
|
261
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
261,
|
|
261
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
259,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
259,
|
|
259
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"c4f5c91cec1c4f59df2ae283d70c8194697a777b",
|
|
"b509437fd330d637bc4043a60bfc8202dfe8b258"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "b55d4fe649118f50cd1aedc1d206791c12f552aa",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "2eea6d4d03bc9adeb2dfb2aa1cfb409f87c02cf5"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-delete-replacement-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
91,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
104,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
108,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
120,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
113,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
104,
|
|
124
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
126,
|
|
129
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
142,
|
|
143
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
135,
|
|
144
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
126,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
147,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
85,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
85,
|
|
172
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
178,
|
|
181
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
191,
|
|
194
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
195,
|
|
196
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
207,
|
|
208
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
200,
|
|
209
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
191,
|
|
211
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
213,
|
|
216
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
217,
|
|
218
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
229,
|
|
230
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
222,
|
|
231
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
213,
|
|
233
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
234,
|
|
239
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
240,
|
|
241
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
252,
|
|
253
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
245,
|
|
254
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
234,
|
|
256
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
258
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
172,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
259
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
96
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
106,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
110,
|
|
111
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
122,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
115,
|
|
124
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
106,
|
|
126
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
128,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
132,
|
|
133
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
145
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
137,
|
|
146
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
128,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
149,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
149,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
87,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
87,
|
|
172
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
259,
|
|
259
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
259,
|
|
259
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
172,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
172
|
|
],
|
|
"number": 3
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"b509437fd330d637bc4043a60bfc8202dfe8b258",
|
|
"b1ef404f85e863410d324f59cc25d4506b4e3385"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "2eea6d4d03bc9adeb2dfb2aa1cfb409f87c02cf5",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "15e1d92065227729bc166fc54669d64a8962e556"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-delete-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
68,
|
|
69
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
80,
|
|
81
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
73,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
86
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
87
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
87
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
96
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
106,
|
|
109
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
110,
|
|
111
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
122,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
115,
|
|
124
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
106,
|
|
126
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
128,
|
|
131
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
132,
|
|
133
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
145
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
137,
|
|
146
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
128,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
149,
|
|
152
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
165,
|
|
166
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
158,
|
|
167
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
149,
|
|
169
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
171
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
87,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
87,
|
|
172
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
172,
|
|
172
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
172,
|
|
172
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
85,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
85,
|
|
85
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"b1ef404f85e863410d324f59cc25d4506b4e3385",
|
|
"2c17f72f428aa0b184cb0b54ce069f9920b8a647"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "15e1d92065227729bc166fc54669d64a8962e556",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "33fab43aeef5fef8b43204de15ff3c779cfb8e1d"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-class-delete-rest-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Class",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
6,
|
|
9
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
19,
|
|
22
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
23,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
35,
|
|
36
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
28,
|
|
37
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
19,
|
|
39
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
41,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
45,
|
|
46
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
57,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
50,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
41,
|
|
61
|
|
]
|
|
},
|
|
{
|
|
"category": "Method",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
62,
|
|
65
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
66,
|
|
67
|
|
]
|
|
},
|
|
{
|
|
"category": "Return",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
78,
|
|
79
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
71,
|
|
80
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
62,
|
|
82
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
84
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
85
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"patch": "delete",
|
|
"range": [
|
|
85,
|
|
85
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
85,
|
|
85
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"class.js",
|
|
"class.js"
|
|
],
|
|
"oids": [
|
|
"2c17f72f428aa0b184cb0b54ce069f9920b8a647",
|
|
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"class.js"
|
|
],
|
|
"sha1": "33fab43aeef5fef8b43204de15ff3c779cfb8e1d",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "3006f046d9d111bbb4429025ca6c5a8fd13b2d64"
|
|
}]
|