1
1
mirror of https://github.com/github/semantic.git synced 2024-12-25 16:02:43 +03:00
semantic/test/corpus/diff-summaries/go/grouped-var-declarations.json

377 lines
12 KiB
JSON
Raw Normal View History

2016-11-02 04:36:43 +03:00
[{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-setup-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"insert": {
"start": [
2016-11-11 00:19:53 +03:00
1,
2016-11-02 04:36:43 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 04:36:43 +03:00
1
2016-11-02 21:37:30 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Added the 'main' module"
2016-11-02 04:36:43 +03:00
}
]
2016-11-02 21:37:30 +03:00
},
"errors": {}
2016-11-02 04:36:43 +03:00
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index e69de29..7905807 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.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 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "9a02b82ed791d6093b557bde927da0db6586a141..9a3f0bd2527843c19792586940c58d9ac7cf1bb1"
2016-11-02 04:36:43 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-insert-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"insert": {
"start": [
2016-11-11 00:19:53 +03:00
4,
2016-11-02 23:46:17 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
7,
2016-11-02 23:46:17 +03:00
2
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Added the 'zero' variable in the main function of the 'main' module"
2016-11-02 23:46:17 +03:00
},
{
"span": {
"insert": {
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 23:46:17 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
7,
2016-11-02 23:46:17 +03:00
2
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Added the 'one' variable in the main function of the 'main' module"
2016-11-02 04:36:43 +03:00
}
]
2016-11-02 21:37:30 +03:00
},
"errors": {}
2016-11-02 04:36:43 +03:00
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index 7905807..cdb45b3 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.go",
2016-12-02 00:03:52 +03:00
"@@ -1,5 +1,8 @@",
" package main",
" ",
" func main() {",
"-",
2016-11-11 00:19:53 +03:00
"+var (",
"+zero = 0",
"+one = 1",
"+)",
2016-12-02 00:03:52 +03:00
" }"
2016-11-11 00:19:53 +03:00
],
2016-11-02 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "9a3f0bd2527843c19792586940c58d9ac7cf1bb1..717fee5a815beb76286193913b4bbdb2cbd4997e"
2016-11-02 04:36:43 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-replacement-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
5,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
5,
5
2016-11-02 04:36:43 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
5,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
5,
2
2016-11-02 04:36:43 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'zero' identifier with the 'a' identifier in the a variable of the 'main' function"
2016-11-02 04:36:43 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
6,
4
2016-11-02 04:36:43 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
6,
2
2016-11-02 04:36:43 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'one' identifier with the 'b' identifier in the b variable of the 'main' function"
2016-11-02 04:36:43 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index cdb45b3..806a593 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.go",
2016-12-02 00:03:52 +03:00
"@@ -2,7 +2,7 @@ package main",
" ",
" func main() {",
2016-11-11 00:19:53 +03:00
" var (",
2016-12-02 00:03:52 +03:00
"-zero = 0",
"-one = 1",
"+a = 0",
"+b = 1",
2016-11-11 00:19:53 +03:00
" )",
2016-12-02 00:03:52 +03:00
" }"
2016-11-11 00:19:53 +03:00
],
2016-11-02 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "717fee5a815beb76286193913b4bbdb2cbd4997e..d8d436d648e0ccad14a54b275301bd7edbed68e1"
2016-11-02 04:36:43 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-delete-replacement-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
5,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
5,
2
2016-11-02 04:36:43 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
5,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
5,
5
2016-11-02 04:36:43 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'a' identifier with the 'zero' identifier in the zero variable of the 'main' function"
2016-11-02 04:36:43 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
6,
2
2016-11-02 04:36:43 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 21:37:30 +03:00
1
2016-11-02 04:36:43 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
6,
4
2016-11-02 04:36:43 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'b' identifier with the 'one' identifier in the one variable of the 'main' function"
2016-11-02 04:36:43 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index 806a593..cdb45b3 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.go",
2016-12-02 00:03:52 +03:00
"@@ -2,7 +2,7 @@ package main",
" ",
" func main() {",
2016-11-11 00:19:53 +03:00
" var (",
"-a = 0",
"-b = 1",
2016-12-02 00:03:52 +03:00
"+zero = 0",
"+one = 1",
2016-11-11 00:19:53 +03:00
" )",
2016-12-02 00:03:52 +03:00
" }"
2016-11-11 00:19:53 +03:00
],
2016-11-02 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "d8d436d648e0ccad14a54b275301bd7edbed68e1..41ea7fd4f753108bf67b181d950fc73642316e01"
2016-11-02 04:36:43 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-delete-insert-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"delete": {
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 04:36:43 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
7,
2016-11-02 23:35:38 +03:00
2
2016-11-02 04:36:43 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Deleted the 'zero' variable in the main function of the 'main' module"
2016-11-02 21:37:30 +03:00
},
2016-11-02 04:36:43 +03:00
{
"span": {
"delete": {
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 04:36:43 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
7,
2016-11-02 23:35:38 +03:00
2
2016-11-02 21:37:30 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Deleted the 'one' variable in the main function of the 'main' module"
2016-11-02 04:36:43 +03:00
}
]
2016-11-02 21:37:30 +03:00
},
"errors": {}
2016-11-02 04:36:43 +03:00
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index cdb45b3..7905807 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.go",
2016-12-02 00:03:52 +03:00
"@@ -1,8 +1,5 @@",
" package main",
" ",
" func main() {",
"-var (",
2016-11-11 00:19:53 +03:00
"-zero = 0",
"-one = 1",
"-)",
2016-12-02 00:03:52 +03:00
"+",
" }"
2016-11-11 00:19:53 +03:00
],
2016-11-02 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "41ea7fd4f753108bf67b181d950fc73642316e01..23ecf547fbb656484104d02b8a712af28b98f248"
2016-11-02 04:36:43 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-grouped-var-declarations-teardown-test",
2016-11-02 04:36:43 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go": [
2016-11-02 04:36:43 +03:00
{
"span": {
"delete": {
"start": [
2016-11-11 00:19:53 +03:00
1,
2016-11-02 04:36:43 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
6,
2016-11-02 04:36:43 +03:00
1
2016-11-02 21:37:30 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Deleted the 'main' module"
2016-11-02 04:36:43 +03:00
}
]
2016-11-02 21:37:30 +03:00
},
"errors": {}
2016-11-02 04:36:43 +03:00
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"grouped-var-declarations.go"
2016-11-02 04:36:43 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/grouped-var-declarations.go b/grouped-var-declarations.go",
2017-01-12 02:28:58 +03:00
"index 7905807..e69de29 100644",
2016-11-11 00:19:53 +03:00
"--- a/grouped-var-declarations.go",
"+++ b/grouped-var-declarations.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 04:36:43 +03:00
"gitDir": "test/corpus/repos/go",
2017-01-12 02:28:58 +03:00
"shas": "23ecf547fbb656484104d02b8a712af28b98f248..23874e933b13d7ac439111764b1ed1443d0a63b0"
2016-11-02 04:36:43 +03:00
}]