1
1
mirror of https://github.com/github/semantic.git synced 2024-12-23 23:11:50 +03:00
semantic/test/corpus/diff-summaries/javascript/class.json
Rob Rix 483e8a3f00 Regenerate all the things!
JavaScript: method call → function call.

Go: regenerated everything.
2017-01-24 15:09:28 -05:00

468 lines
15 KiB
JSON

[{
"testCaseDescription": "javascript-class-insert-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"insert": {
"start": [
1,
1
],
"end": [
1,
87
]
}
},
"summary": "Added the 'Foo' class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index e69de29b..8f6ae64d 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -0,0 +1 @@",
"+class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "d9d6e19c015a3f2dbb9d04d3867b13889dd798ac..05fc0916c3ad9408a0e1b0fd90bb83d43628e892"
}
,{
"testCaseDescription": "javascript-class-replacement-insert-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"insert": {
"start": [
1,
1
],
"end": [
1,
85
]
}
},
"summary": "Added the 'Foo' class"
},
{
"span": {
"insert": {
"start": [
2,
1
],
"end": [
2,
87
]
}
},
"summary": "Added the 'Foo' class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index 8f6ae64d..b509437f 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1 +1,3 @@",
"+class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }",
"+class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "05fc0916c3ad9408a0e1b0fd90bb83d43628e892..4204d9bb3c5c1cfab6dc2b6af925b0666d015cb0"
}
,{
"testCaseDescription": "javascript-class-delete-insert-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"replace": [
{
"start": [
1,
20
],
"end": [
1,
23
]
},
{
"start": [
1,
20
],
"end": [
1,
23
]
}
]
},
"summary": "Replaced the 'foo' identifier with the 'one' identifier in the 'one(a)' method of the 'Foo' class"
},
{
"span": {
"insert": {
"start": [
1,
42
],
"end": [
1,
62
]
}
},
"summary": "Added the 'two(b)' method in the Foo class"
},
{
"span": {
"insert": {
"start": [
1,
63
],
"end": [
1,
85
]
}
},
"summary": "Added the 'three(c)' method in the Foo class"
},
{
"span": {
"delete": {
"start": [
1,
42
],
"end": [
1,
62
]
}
},
"summary": "Deleted the 'bar(b)' method in the Foo class"
},
{
"span": {
"delete": {
"start": [
1,
63
],
"end": [
1,
83
]
}
},
"summary": "Deleted the 'baz(c)' method in the Foo class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index b509437f..c4f5c91c 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1,3 +1,3 @@",
"-class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }",
"+class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "4204d9bb3c5c1cfab6dc2b6af925b0666d015cb0..18b9de02fda94811dad14657d61160c8943b6576"
}
,{
"testCaseDescription": "javascript-class-replacement-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"replace": [
{
"start": [
1,
20
],
"end": [
1,
23
]
},
{
"start": [
1,
20
],
"end": [
1,
23
]
}
]
},
"summary": "Replaced the 'one' identifier with the 'foo' identifier in the 'foo(a)' method of the 'Foo' class"
},
{
"span": {
"insert": {
"start": [
1,
42
],
"end": [
1,
62
]
}
},
"summary": "Added the 'bar(b)' method in the Foo class"
},
{
"span": {
"insert": {
"start": [
1,
63
],
"end": [
1,
83
]
}
},
"summary": "Added the 'baz(c)' method in the Foo class"
},
{
"span": {
"delete": {
"start": [
1,
42
],
"end": [
1,
62
]
}
},
"summary": "Deleted the 'two(b)' method in the Foo class"
},
{
"span": {
"delete": {
"start": [
1,
63
],
"end": [
1,
85
]
}
},
"summary": "Deleted the 'three(c)' method in the Foo class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index c4f5c91c..b509437f 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1,3 +1,3 @@",
"-class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
"+class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "18b9de02fda94811dad14657d61160c8943b6576..c4c35843b5c7aa3d018d196d8fb86f2495b7881c"
}
,{
"testCaseDescription": "javascript-class-delete-replacement-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
85
]
}
},
"summary": "Deleted the 'Foo' class"
},
{
"span": {
"delete": {
"start": [
2,
1
],
"end": [
2,
87
]
}
},
"summary": "Deleted the 'Foo' class"
},
{
"span": {
"insert": {
"start": [
2,
1
],
"end": [
2,
85
]
}
},
"summary": "Added the 'Foo' class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index b509437f..b1ef404f 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1,3 +1,2 @@",
"-class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }",
"-class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
"+class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "c4c35843b5c7aa3d018d196d8fb86f2495b7881c..af0a7a4e55d3b67109f4455766d91410a6113c76"
}
,{
"testCaseDescription": "javascript-class-delete-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
87
]
}
},
"summary": "Deleted the 'Foo' class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index b1ef404f..2c17f72f 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1,2 +1 @@",
"-class Foo { static one(a) { return a; }; two(b) { return b; } three(c) { return c; } }",
" class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "af0a7a4e55d3b67109f4455766d91410a6113c76..417e7b1dc2606c4235a0fecf05b8d1c3c170f661"
}
,{
"testCaseDescription": "javascript-class-delete-rest-test",
"expectedResult": {
"changes": {
"class.js": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
85
]
}
},
"summary": "Deleted the 'Foo' class"
}
]
},
"errors": {}
},
"filePaths": [
"class.js"
],
"patch": [
"diff --git a/class.js b/class.js",
"index 2c17f72f..e69de29b 100644",
"--- a/class.js",
"+++ b/class.js",
"@@ -1 +0,0 @@",
"-class Foo { static foo(a) { return a; }; bar(b) { return b; } baz(c) { return c; } }"
],
"gitDir": "test/corpus/repos/javascript",
"shas": "417e7b1dc2606c4235a0fecf05b8d1c3c170f661..89b3d4cd2ef38999c223c69de3011646b1f43c24"
}]