mirror of
https://github.com/github/semantic.git
synced 2024-12-23 14:54:16 +03:00
2766 lines
136 KiB
JSON
2766 lines
136 KiB
JSON
[{
|
|
"testCaseDescription": "javascript-generator-function-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"patch": "insert",
|
|
"range": [
|
|
60,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
60,
|
|
60
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391",
|
|
"04e8a59bc45444cc298c2142de90af10b8386bf3"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "30c4bb9aa0ee4258642712a4bc51a8d5b90217c0",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "d4ea8dff1dd80af5a7f4caba2a2f9d2c5afd7b74"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-replacement-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
73,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
63,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
63,
|
|
123
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
133,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
151
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
157
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
161,
|
|
167
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
174,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
168,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
159,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
182
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
183
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
60,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
60,
|
|
60
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
183,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
183,
|
|
183
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"04e8a59bc45444cc298c2142de90af10b8386bf3",
|
|
"ed5c0370f5abc30c2f381fe513447b205647aebc"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "d4ea8dff1dd80af5a7f4caba2a2f9d2c5afd7b74",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "7e08ee0f8b53e8e1312fba7ca8ae6ccb1f5bcfc6"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-delete-insert-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
73,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
63,
|
|
123
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
70,
|
|
83
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
84,
|
|
88
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
90,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
98,
|
|
104
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
111,
|
|
115
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
105,
|
|
116
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
96,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
120
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
60,
|
|
120
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
133,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
151
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
157
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
161,
|
|
167
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
174,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
168,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
159,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
182
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
183
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
143
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
150,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
158,
|
|
164
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
171,
|
|
175
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
165,
|
|
176
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
156,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
180
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
120,
|
|
180
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
183,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
183,
|
|
183
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
180,
|
|
180
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
180,
|
|
180
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"ed5c0370f5abc30c2f381fe513447b205647aebc",
|
|
"0895c3fde3cba1e850e4730eb193f62270215e70"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "7e08ee0f8b53e8e1312fba7ca8ae6ccb1f5bcfc6",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "788c33daa9346419673699f444935509c34c3342"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-replacement-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"patch": "replace",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
70,
|
|
83
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
84,
|
|
88
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
90,
|
|
94
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
98,
|
|
104
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
111,
|
|
115
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
105,
|
|
116
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
96,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
120
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
60,
|
|
120
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
73,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
63,
|
|
123
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
130,
|
|
143
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
144,
|
|
148
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
150,
|
|
154
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
158,
|
|
164
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
171,
|
|
175
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
165,
|
|
176
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
156,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
120,
|
|
180
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
120,
|
|
180
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
133,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
151
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
157
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
161,
|
|
167
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
174,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
168,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
159,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
182
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
183
|
|
],
|
|
"number": 3
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
180,
|
|
180
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
180,
|
|
180
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
183,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
183,
|
|
183
|
|
],
|
|
"number": 4
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"0895c3fde3cba1e850e4730eb193f62270215e70",
|
|
"ed5c0370f5abc30c2f381fe513447b205647aebc"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "788c33daa9346419673699f444935509c34c3342",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "557c2f9449057a74ec70ed2415bec5d241e25b56"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-delete-replacement-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
73,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
63,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
63,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
63,
|
|
123
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
133,
|
|
146
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
147,
|
|
151
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
153,
|
|
157
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
161,
|
|
167
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
174,
|
|
178
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
168,
|
|
179
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
159,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
181
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
182
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
123,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
183
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
70,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"patch": "insert",
|
|
"range": [
|
|
60,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
60,
|
|
123
|
|
],
|
|
"number": 2
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
183,
|
|
183
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
183,
|
|
183
|
|
],
|
|
"number": 4
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
123,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
123
|
|
],
|
|
"number": 3
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"ed5c0370f5abc30c2f381fe513447b205647aebc",
|
|
"1dae1059cf36b86fdb5fa7cdf701f28709470b90"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "557c2f9449057a74ec70ed2415bec5d241e25b56",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "5273e2f0c602f9347d0b98221964849b3c8ac967"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-delete-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
23
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
24,
|
|
28
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
30,
|
|
34
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
38,
|
|
44
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
51,
|
|
55
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
45,
|
|
56
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
36,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
60
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
60
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
70,
|
|
86
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
87,
|
|
91
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
93,
|
|
97
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
101,
|
|
107
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
114,
|
|
118
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
108,
|
|
119
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
99,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
121
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
122
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
60,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
60,
|
|
123
|
|
],
|
|
"number": 2
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
123,
|
|
123
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
123,
|
|
123
|
|
],
|
|
"number": 3
|
|
},
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"range": [
|
|
63,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": false,
|
|
"range": [
|
|
63,
|
|
63
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"1dae1059cf36b86fdb5fa7cdf701f28709470b90",
|
|
"5846d1c0997bed696b602367f89d69b35822caac"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "5273e2f0c602f9347d0b98221964849b3c8ac967",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "767cd72e437bef2a33b3306b0b3f265fa82ea566"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-generator-function-delete-rest-test",
|
|
"expectedResult": {
|
|
"rows": [
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "Function",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
10,
|
|
26
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
27,
|
|
31
|
|
]
|
|
},
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
33,
|
|
37
|
|
]
|
|
},
|
|
{
|
|
"category": "ExpressionStatements",
|
|
"children": [
|
|
{
|
|
"category": "yield_statement",
|
|
"range": [
|
|
41,
|
|
47
|
|
]
|
|
},
|
|
{
|
|
"category": "yield_statement",
|
|
"children": [
|
|
{
|
|
"category": "Identifier",
|
|
"range": [
|
|
54,
|
|
58
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
48,
|
|
59
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
39,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
61
|
|
]
|
|
}
|
|
],
|
|
"range": [
|
|
0,
|
|
62
|
|
]
|
|
}
|
|
],
|
|
"patch": "delete",
|
|
"range": [
|
|
0,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
0,
|
|
63
|
|
],
|
|
"number": 1
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"terms": [
|
|
{
|
|
"category": "Program",
|
|
"children": [],
|
|
"patch": "delete",
|
|
"range": [
|
|
63,
|
|
63
|
|
]
|
|
}
|
|
],
|
|
"hasChanges": true,
|
|
"range": [
|
|
63,
|
|
63
|
|
],
|
|
"number": 2
|
|
}
|
|
]
|
|
],
|
|
"paths": [
|
|
"generator-function.js",
|
|
"generator-function.js"
|
|
],
|
|
"oids": [
|
|
"5846d1c0997bed696b602367f89d69b35822caac",
|
|
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391"
|
|
]
|
|
},
|
|
"filePaths": [
|
|
"generator-function.js"
|
|
],
|
|
"sha1": "767cd72e437bef2a33b3306b0b3f265fa82ea566",
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"sha2": "832e08d36d9f52bc1b62f075e695378c990f6a7d"
|
|
}]
|