1
1
mirror of https://github.com/github/semantic.git synced 2024-12-23 06:41:45 +03:00
semantic/test/corpus/json/javascript/void-operator.json
2016-11-01 10:03:25 -05:00

1804 lines
74 KiB
JSON

[{
"testCaseDescription": "javascript-void-operator-insert-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"patch": "insert",
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"patch": "insert",
"range": [
9,
9
]
}
],
"hasChanges": true,
"range": [
9,
9
],
"number": 2
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391",
"02aa7503dc8ff53da9bbc799ec096fab6722a710"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "3b3e34ea731db036313d86070de8dbcc3fac5fb8",
"gitDir": "test/corpus/repos/javascript",
"sha2": "3709d6acb927438ba272440b358d0c0f765a7f7d"
}
,{
"testCaseDescription": "javascript-void-operator-replacement-insert-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"patch": "insert",
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"patch": "insert",
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": true,
"range": [
9,
18
],
"number": 2
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": false,
"range": [
0,
9
],
"number": 1
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
9,
9
]
}
],
"hasChanges": false,
"range": [
9,
9
],
"number": 2
},
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"02aa7503dc8ff53da9bbc799ec096fab6722a710",
"c493dc5b297d4a28578405f7595136bc5c45b142"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "3709d6acb927438ba272440b358d0c0f765a7f7d",
"gitDir": "test/corpus/repos/javascript",
"sha2": "663d6938a8c260915f0e1b832b15e259746c73c0"
}
,{
"testCaseDescription": "javascript-void-operator-delete-insert-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"patch": "replace",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"patch": "replace",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": false,
"range": [
9,
18
],
"number": 2
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": false,
"range": [
9,
18
],
"number": 2
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
},
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"c493dc5b297d4a28578405f7595136bc5c45b142",
"aae2f63329410ef98f4308a4f7e48412dee52573"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "663d6938a8c260915f0e1b832b15e259746c73c0",
"gitDir": "test/corpus/repos/javascript",
"sha2": "fcc58942b02161391292826681275152579ec190"
}
,{
"testCaseDescription": "javascript-void-operator-replacement-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"patch": "replace",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"patch": "replace",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": false,
"range": [
9,
18
],
"number": 2
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": false,
"range": [
9,
18
],
"number": 2
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
},
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"aae2f63329410ef98f4308a4f7e48412dee52573",
"c493dc5b297d4a28578405f7595136bc5c45b142"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "fcc58942b02161391292826681275152579ec190",
"gitDir": "test/corpus/repos/javascript",
"sha2": "dcd3e048a32d8de5774706b671e4b290bfd93dd7"
}
,{
"testCaseDescription": "javascript-void-operator-delete-replacement-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"patch": "delete",
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"patch": "delete",
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": true,
"range": [
9,
18
],
"number": 2
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
23,
24
]
}
],
"range": [
23,
26
]
}
],
"range": [
18,
26
]
}
],
"range": [
18,
27
]
}
],
"range": [
18,
27
]
}
],
"hasChanges": false,
"range": [
18,
27
],
"number": 3
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": false,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"patch": "insert",
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": true,
"range": [
9,
18
],
"number": 2
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
27,
27
]
}
],
"hasChanges": false,
"range": [
27,
27
],
"number": 4
},
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
18,
18
]
}
],
"hasChanges": false,
"range": [
18,
18
],
"number": 3
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"c493dc5b297d4a28578405f7595136bc5c45b142",
"738c34a4b4b1bec1034d08b39dbb4e6ae84d0969"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "dcd3e048a32d8de5774706b671e4b290bfd93dd7",
"gitDir": "test/corpus/repos/javascript",
"sha2": "287e57bd031fb2a5f79bf799909eaa171aecc4ef"
}
,{
"testCaseDescription": "javascript-void-operator-delete-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"patch": "delete",
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
14,
15
]
}
],
"range": [
14,
17
]
}
],
"range": [
9,
17
]
}
],
"range": [
9,
18
]
}
],
"range": [
9,
18
]
}
],
"hasChanges": false,
"range": [
9,
18
],
"number": 2
},
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"range": [
0,
9
]
}
],
"hasChanges": false,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
18,
18
]
}
],
"hasChanges": false,
"range": [
18,
18
],
"number": 3
},
{
"terms": [
{
"category": "Program",
"children": [],
"range": [
9,
9
]
}
],
"hasChanges": false,
"range": [
9,
9
],
"number": 2
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"738c34a4b4b1bec1034d08b39dbb4e6ae84d0969",
"8e9ceba22d3880a43e333fe0d6b5c7d34cdb1e41"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "287e57bd031fb2a5f79bf799909eaa171aecc4ef",
"gitDir": "test/corpus/repos/javascript",
"sha2": "1f10d0ccbe95d222384139565cd0cdde47e31338"
}
,{
"testCaseDescription": "javascript-void-operator-delete-rest-test",
"expectedResult": {
"rows": [
[
{
"terms": [
{
"category": "Program",
"children": [
{
"category": "ExpressionStatements",
"children": [
{
"category": "Operator",
"children": [
{
"category": "FunctionCall",
"children": [
{
"category": "Identifier",
"range": [
5,
6
]
}
],
"range": [
5,
8
]
}
],
"range": [
0,
8
]
}
],
"range": [
0,
9
]
}
],
"patch": "delete",
"range": [
0,
9
]
}
],
"hasChanges": true,
"range": [
0,
9
],
"number": 1
}
],
[
{
"terms": [
{
"category": "Program",
"children": [],
"patch": "delete",
"range": [
9,
9
]
}
],
"hasChanges": true,
"range": [
9,
9
],
"number": 2
}
]
],
"paths": [
"void-operator.js",
"void-operator.js"
],
"oids": [
"8e9ceba22d3880a43e333fe0d6b5c7d34cdb1e41",
"e69de29bb2d1d6434b8b29ae775ad8c2e48c5391"
]
},
"filePaths": [
"void-operator.js"
],
"sha1": "1f10d0ccbe95d222384139565cd0cdde47e31338",
"gitDir": "test/corpus/repos/javascript",
"sha2": "a3e54c848b4eb2c76ca34eeb421299dd5350e606"
}]