1
1
mirror of https://github.com/github/semantic.git synced 2024-12-23 14:54:16 +03:00
semantic/test/corpus/diff-summaries/go/variadic-function-declarations.json
2016-11-14 17:26:06 -05:00

728 lines
24 KiB
JSON

[{
"testCaseDescription": "go-variadic-function-declarations-insert-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"insert": {
"start": [
1,
1
],
"end": [
1,
22
]
}
},
"summary": "Added the 'f1' function"
},
{
"span": {
"insert": {
"start": [
2,
1
],
"end": [
2,
19
]
}
},
"summary": "Added the 'f2' function"
},
{
"span": {
"insert": {
"start": [
3,
1
],
"end": [
3,
23
]
}
},
"summary": "Added the 'f3' function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index e69de29..e9d461f 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -0,0 +1,3 @@",
"+func f1(a ...*int) {}",
"+func f2(...int) {}",
"+func f3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "636e6398ed2d7f4af5574d1ecd45576a57d59579..f461adf1532fe9d1087aff11d8129dfa23f721c4"
}
,{
"testCaseDescription": "go-variadic-function-declarations-replacement-insert-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"insert": {
"start": [
1,
1
],
"end": [
1,
22
]
}
},
"summary": "Added the 'g1' function"
},
{
"span": {
"insert": {
"start": [
2,
1
],
"end": [
2,
19
]
}
},
"summary": "Added the 'g2' function"
},
{
"span": {
"insert": {
"start": [
3,
1
],
"end": [
3,
23
]
}
},
"summary": "Added the 'g3' function"
},
{
"span": {
"insert": {
"start": [
4,
1
],
"end": [
4,
22
]
}
},
"summary": "Added the 'f1' function"
},
{
"span": {
"insert": {
"start": [
5,
1
],
"end": [
5,
19
]
}
},
"summary": "Added the 'f2' function"
},
{
"span": {
"insert": {
"start": [
6,
1
],
"end": [
6,
23
]
}
},
"summary": "Added the 'f3' function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index e9d461f..1e4f816 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,3 +1,9 @@",
"+func g1(a ...*int) {}",
"+func g2(...int) {}",
"+func g3(a, ...bool) {}",
"+func f1(a ...*int) {}",
"+func f2(...int) {}",
"+func f3(a, ...bool) {}",
" func f1(a ...*int) {}",
" func f2(...int) {}",
" func f3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "f461adf1532fe9d1087aff11d8129dfa23f721c4..f3cc5728609c25c9305462f0fe2a28e9dfa21424"
}
,{
"testCaseDescription": "go-variadic-function-declarations-delete-insert-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"replace": [
{
"start": [
1,
6
],
"end": [
1,
8
]
},
{
"start": [
1,
6
],
"end": [
1,
8
]
}
]
},
"summary": "Replaced the 'g1' identifier with the 'f1' identifier in the f1 function"
},
{
"span": {
"replace": [
{
"start": [
2,
6
],
"end": [
2,
8
]
},
{
"start": [
2,
6
],
"end": [
2,
8
]
}
]
},
"summary": "Replaced the 'g2' identifier with the 'f2' identifier in the f2 function"
},
{
"span": {
"replace": [
{
"start": [
3,
6
],
"end": [
3,
8
]
},
{
"start": [
3,
6
],
"end": [
3,
8
]
}
]
},
"summary": "Replaced the 'g3' identifier with the 'f3' identifier in the f3 function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index 1e4f816..3198ec6 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,6 +1,6 @@",
"-func g1(a ...*int) {}",
"-func g2(...int) {}",
"-func g3(a, ...bool) {}",
"+func f1(a ...*int) {}",
"+func f2(...int) {}",
"+func f3(a, ...bool) {}",
" func f1(a ...*int) {}",
" func f2(...int) {}",
" func f3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "f3cc5728609c25c9305462f0fe2a28e9dfa21424..62b3ee4571d63e1c2507a57c7e9e42e3b9383f84"
}
,{
"testCaseDescription": "go-variadic-function-declarations-replacement-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"replace": [
{
"start": [
1,
6
],
"end": [
1,
8
]
},
{
"start": [
1,
6
],
"end": [
1,
8
]
}
]
},
"summary": "Replaced the 'f1' identifier with the 'g1' identifier in the g1 function"
},
{
"span": {
"replace": [
{
"start": [
2,
6
],
"end": [
2,
8
]
},
{
"start": [
2,
6
],
"end": [
2,
8
]
}
]
},
"summary": "Replaced the 'f2' identifier with the 'g2' identifier in the g2 function"
},
{
"span": {
"replace": [
{
"start": [
3,
6
],
"end": [
3,
8
]
},
{
"start": [
3,
6
],
"end": [
3,
8
]
}
]
},
"summary": "Replaced the 'f3' identifier with the 'g3' identifier in the g3 function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index 3198ec6..1e4f816 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,6 +1,6 @@",
"-func f1(a ...*int) {}",
"-func f2(...int) {}",
"-func f3(a, ...bool) {}",
"+func g1(a ...*int) {}",
"+func g2(...int) {}",
"+func g3(a, ...bool) {}",
" func f1(a ...*int) {}",
" func f2(...int) {}",
" func f3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "62b3ee4571d63e1c2507a57c7e9e42e3b9383f84..704e30440767bcae274e6cd5cc7fa209fab4295c"
}
,{
"testCaseDescription": "go-variadic-function-declarations-delete-replacement-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
22
]
}
},
"summary": "Deleted the 'g1' function"
},
{
"span": {
"delete": {
"start": [
2,
1
],
"end": [
2,
19
]
}
},
"summary": "Deleted the 'g2' function"
},
{
"span": {
"delete": {
"start": [
3,
1
],
"end": [
3,
23
]
}
},
"summary": "Deleted the 'g3' function"
},
{
"span": {
"delete": {
"start": [
4,
1
],
"end": [
4,
22
]
}
},
"summary": "Deleted the 'f1' function"
},
{
"span": {
"delete": {
"start": [
5,
1
],
"end": [
5,
19
]
}
},
"summary": "Deleted the 'f2' function"
},
{
"span": {
"delete": {
"start": [
6,
1
],
"end": [
6,
23
]
}
},
"summary": "Deleted the 'f3' function"
},
{
"span": {
"insert": {
"start": [
4,
1
],
"end": [
4,
22
]
}
},
"summary": "Added the 'g1' function"
},
{
"span": {
"insert": {
"start": [
5,
1
],
"end": [
5,
19
]
}
},
"summary": "Added the 'g2' function"
},
{
"span": {
"insert": {
"start": [
6,
1
],
"end": [
6,
23
]
}
},
"summary": "Added the 'g3' function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index 1e4f816..99d1e54 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,9 +1,6 @@",
"-func g1(a ...*int) {}",
"-func g2(...int) {}",
"-func g3(a, ...bool) {}",
"-func f1(a ...*int) {}",
"-func f2(...int) {}",
"-func f3(a, ...bool) {}",
" func f1(a ...*int) {}",
" func f2(...int) {}",
" func f3(a, ...bool) {}",
"+func g1(a ...*int) {}",
"+func g2(...int) {}",
"+func g3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "704e30440767bcae274e6cd5cc7fa209fab4295c..55375be861adfddb149deb9d6768784dc87fa5c1"
}
,{
"testCaseDescription": "go-variadic-function-declarations-delete-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
22
]
}
},
"summary": "Deleted the 'f1' function"
},
{
"span": {
"delete": {
"start": [
2,
1
],
"end": [
2,
19
]
}
},
"summary": "Deleted the 'f2' function"
},
{
"span": {
"delete": {
"start": [
3,
1
],
"end": [
3,
23
]
}
},
"summary": "Deleted the 'f3' function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index 99d1e54..4a0a10b 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,6 +1,3 @@",
"-func f1(a ...*int) {}",
"-func f2(...int) {}",
"-func f3(a, ...bool) {}",
" func g1(a ...*int) {}",
" func g2(...int) {}",
" func g3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "55375be861adfddb149deb9d6768784dc87fa5c1..fe368f60695a9d74096e13a4143704b844e693b2"
}
,{
"testCaseDescription": "go-variadic-function-declarations-delete-rest-test",
"expectedResult": {
"changes": {
"variadic-function-declarations.go": [
{
"span": {
"delete": {
"start": [
1,
1
],
"end": [
1,
22
]
}
},
"summary": "Deleted the 'g1' function"
},
{
"span": {
"delete": {
"start": [
2,
1
],
"end": [
2,
19
]
}
},
"summary": "Deleted the 'g2' function"
},
{
"span": {
"delete": {
"start": [
3,
1
],
"end": [
3,
23
]
}
},
"summary": "Deleted the 'g3' function"
}
]
},
"errors": {}
},
"filePaths": [
"variadic-function-declarations.go"
],
"patch": [
"diff --git a/variadic-function-declarations.go b/variadic-function-declarations.go",
"index 4a0a10b..e69de29 100644",
"--- a/variadic-function-declarations.go",
"+++ b/variadic-function-declarations.go",
"@@ -1,3 +0,0 @@",
"-func g1(a ...*int) {}",
"-func g2(...int) {}",
"-func g3(a, ...bool) {}"
],
"gitDir": "test/corpus/repos/go",
"shas": "fe368f60695a9d74096e13a4143704b844e693b2..be25e7cbaf4d59fc1f6b071a3c17589ad1e18f75"
}]