2016-11-02 17:50:05 +03:00
|
|
|
[{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-call-expressions-setup-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"changes": {
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
2016-11-11 00:19:53 +03:00
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-02 00:03:52 +03:00
|
|
|
6,
|
2016-11-11 00:19:53 +03:00
|
|
|
1
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:03:52 +03:00
|
|
|
"summary": "Added the 'main' module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:03:52 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go"
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index e69de29..7905807 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -0,0 +1,5 @@",
|
|
|
|
"+package main",
|
|
|
|
"+",
|
|
|
|
"+func main() {",
|
|
|
|
"+",
|
|
|
|
"+}"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "a6d6b87e3b8498575c6a100bd3722f8ce2d30eee..ecb64feb9685dca8e3a1a2caf500a07d110629f9"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-call-expressions-insert-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
2016-12-02 00:07:40 +03:00
|
|
|
"changes": {
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-11-11 00:19:53 +03:00
|
|
|
4,
|
2016-11-02 21:37:30 +03:00
|
|
|
1
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-11-11 00:19:53 +03:00
|
|
|
4,
|
2016-11-22 23:10:04 +03:00
|
|
|
11
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Added the 'x(b, c)' function call in the main function of the 'main' module"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-11-11 00:19:53 +03:00
|
|
|
5,
|
2016-11-02 21:37:30 +03:00
|
|
|
1
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-11-11 00:19:53 +03:00
|
|
|
5,
|
2016-11-22 23:10:04 +03:00
|
|
|
9
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Added the 'y(b, c)' function call in the main function of the 'main' module"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-11-11 00:19:53 +03:00
|
|
|
6,
|
2016-11-02 21:37:30 +03:00
|
|
|
1
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-11-11 00:19:53 +03:00
|
|
|
6,
|
2016-11-22 23:10:04 +03:00
|
|
|
11
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Added the 'z(b, c)' function call in the main function of the 'main' module"
|
2016-11-02 21:37:30 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:07:40 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 21:37:30 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"call-expressions.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index 7905807..72918e5 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,5 +1,7 @@",
|
|
|
|
" package main",
|
|
|
|
" ",
|
|
|
|
" func main() {",
|
|
|
|
"-",
|
2016-11-11 00:19:53 +03:00
|
|
|
"+x(b, c...)",
|
|
|
|
"+y(b, c,)",
|
|
|
|
"+z(b,c...,)",
|
2016-12-02 00:03:52 +03:00
|
|
|
" }"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 21:37:30 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "ecb64feb9685dca8e3a1a2caf500a07d110629f9..e679eabd7abb1171b86f17c7118a30a60ac9401e"
|
2016-11-22 23:10:04 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "go-call-expressions-replacement-test",
|
|
|
|
"expectedResult": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"changes": {
|
2016-11-22 23:10:04 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
4,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
4,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
4,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
4,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'x' identifier with the 'a' identifier in the a(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'y' identifier with the 'b' identifier in the b(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
6,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
6,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
6,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
6,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'z' identifier with the 'c' identifier in the c(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:03:52 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go"
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index 72918e5..2d5e765 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,7 +1,7 @@",
|
|
|
|
" package main",
|
|
|
|
" ",
|
|
|
|
" func main() {",
|
2016-11-11 00:19:53 +03:00
|
|
|
"-x(b, c...)",
|
|
|
|
"-y(b, c,)",
|
|
|
|
"-z(b,c...,)",
|
|
|
|
"+a(b, c...)",
|
|
|
|
"+b(b, c,)",
|
2016-11-22 23:10:04 +03:00
|
|
|
"+c(b,c...,)",
|
2016-12-02 00:03:52 +03:00
|
|
|
" }"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "e679eabd7abb1171b86f17c7118a30a60ac9401e..17af9b349ce778f930c9566cdec742dc1477bb4b"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-11-22 23:10:04 +03:00
|
|
|
"testCaseDescription": "go-call-expressions-delete-replacement-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"changes": {
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
4,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
4,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
4,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
4,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'a' identifier with the 'x' identifier in the x(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'b' identifier with the 'y' identifier in the y(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
6,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
6,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
6,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
6,
|
|
|
|
2
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Replaced the 'c' identifier with the 'z' identifier in the z(b, c) function call of the 'main' function"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:03:52 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go"
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index 2d5e765..72918e5 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,7 +1,7 @@",
|
|
|
|
" package main",
|
|
|
|
" ",
|
|
|
|
" func main() {",
|
2016-11-22 23:10:04 +03:00
|
|
|
"-a(b, c...)",
|
|
|
|
"-b(b, c,)",
|
|
|
|
"-c(b,c...,)",
|
2016-12-02 00:03:52 +03:00
|
|
|
"+x(b, c...)",
|
|
|
|
"+y(b, c,)",
|
|
|
|
"+z(b,c...,)",
|
|
|
|
" }"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "17af9b349ce778f930c9566cdec742dc1477bb4b..4666ff91d68871a70e66dc234d80bbbe74ba5737"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-call-expressions-delete-insert-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
2016-12-02 00:07:40 +03:00
|
|
|
"changes": {
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
2016-11-11 00:19:53 +03:00
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-12-02 00:03:52 +03:00
|
|
|
4,
|
2016-11-11 00:19:53 +03:00
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-02 00:03:52 +03:00
|
|
|
4,
|
2016-11-22 23:10:04 +03:00
|
|
|
11
|
2016-11-11 00:19:53 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Deleted the 'x(b, c)' function call in the main function of the 'main' module"
|
2016-11-11 00:19:53 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-12-02 00:03:52 +03:00
|
|
|
5,
|
2016-11-11 00:19:53 +03:00
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-02 00:03:52 +03:00
|
|
|
5,
|
2016-11-22 23:10:04 +03:00
|
|
|
9
|
2016-11-11 00:19:53 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Deleted the 'y(b, c)' function call in the main function of the 'main' module"
|
2016-11-11 00:19:53 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-12-02 00:03:52 +03:00
|
|
|
6,
|
2016-11-22 23:10:04 +03:00
|
|
|
1
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-02 00:03:52 +03:00
|
|
|
6,
|
2016-11-22 23:10:04 +03:00
|
|
|
11
|
2016-11-11 00:19:53 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:07:40 +03:00
|
|
|
"summary": "Deleted the 'z(b, c)' function call in the main function of the 'main' module"
|
2016-11-22 23:10:04 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:07:40 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-22 23:10:04 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"call-expressions.go"
|
|
|
|
],
|
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index 72918e5..7905807 100644",
|
2016-11-22 23:10:04 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,7 +1,5 @@",
|
|
|
|
" package main",
|
|
|
|
" ",
|
|
|
|
" func main() {",
|
2016-11-22 23:10:04 +03:00
|
|
|
"-x(b, c...)",
|
|
|
|
"-y(b, c,)",
|
|
|
|
"-z(b,c...,)",
|
2016-12-02 00:03:52 +03:00
|
|
|
"+",
|
|
|
|
" }"
|
2016-11-22 23:10:04 +03:00
|
|
|
],
|
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "4666ff91d68871a70e66dc234d80bbbe74ba5737..22508dbaaf87e757f0d1383438121d63bbfb184d"
|
2016-11-22 23:10:04 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-call-expressions-teardown-test",
|
2016-11-22 23:10:04 +03:00
|
|
|
"expectedResult": {
|
2016-12-02 00:03:52 +03:00
|
|
|
"changes": {
|
2016-11-22 23:10:04 +03:00
|
|
|
"call-expressions.go": [
|
2016-11-11 00:19:53 +03:00
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-11-22 23:10:04 +03:00
|
|
|
1,
|
2016-11-11 00:19:53 +03:00
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-02 00:03:52 +03:00
|
|
|
6,
|
2016-11-22 23:10:04 +03:00
|
|
|
1
|
2016-11-11 00:19:53 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2016-12-02 00:03:52 +03:00
|
|
|
"summary": "Deleted the 'main' module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-02 00:03:52 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
2016-11-02 21:37:30 +03:00
|
|
|
"call-expressions.go"
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/call-expressions.go b/call-expressions.go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"index 7905807..e69de29 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/call-expressions.go",
|
|
|
|
"+++ b/call-expressions.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,5 +0,0 @@",
|
|
|
|
"-package main",
|
|
|
|
"-",
|
|
|
|
"-func main() {",
|
|
|
|
"-",
|
|
|
|
"-}"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-12 02:28:58 +03:00
|
|
|
"shas": "22508dbaaf87e757f0d1383438121d63bbfb184d..3e502021cd3d8c7e11e89ade83196888145fb71f"
|
2016-11-02 17:50:05 +03:00
|
|
|
}]
|