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/selector-expressions.json

389 lines
12 KiB
JSON
Raw Normal View History

2016-11-02 17:50:05 +03:00
[{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-setup-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-expressions.go": [
2016-11-02 17:50:05 +03:00
{
"span": {
"insert": {
"start": [
2016-11-11 00:19:53 +03:00
1,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
6,
1
2016-11-02 17:50:05 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Added the 'main' module"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index e69de29..7905807 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-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": "ddf3ce8b6c6271e3153414e94c2a5ed576525b3f..f65051e093ea9f1b853ad6607b0627bc4b467b71"
2016-11-02 17:50:05 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-insert-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-expressions.go": [
2016-11-02 17:50:05 +03:00
{
"span": {
2016-11-11 00:19:53 +03:00
"insert": {
"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-11 00:19:53 +03:00
8
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Added the 'a[b][c]()' function call in the main function of the 'main' module"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index 7905807..8b4c745 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-expressions.go",
2016-12-02 00:03:52 +03:00
"@@ -1,5 +1,5 @@",
" package main",
" ",
" func main() {",
"-",
2016-11-11 00:19:53 +03:00
"+a.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": "f65051e093ea9f1b853ad6607b0627bc4b467b71..9e976318322531cbe98ab23f961842da2c2fb84a"
2016-11-02 17:50:05 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-replacement-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-expressions.go": [
2016-11-02 17:50:05 +03:00
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
2
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
2
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'a' identifier with the 'x' identifier in the x[y] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
3
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
4
2016-11-02 17:50:05 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
3
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
4
2016-11-02 17:50:05 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'b' identifier with the 'y' identifier in the x[y] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
5
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
6
2016-11-02 17:50:05 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
5
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
6
2016-11-02 17:50:05 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'c' identifier with the 'z' identifier in the x[y][z] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index 8b4c745..0e519e3 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-expressions.go",
2016-12-02 00:03:52 +03:00
"@@ -1,5 +1,5 @@",
" package main",
" ",
" func main() {",
"-a.b.c()",
"+x.y.z()",
" }"
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": "9e976318322531cbe98ab23f961842da2c2fb84a..afd5153ab50147c234de8b3757736f30d7efe411"
2016-11-02 17:50:05 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-delete-replacement-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-expressions.go": [
2016-11-02 17:50:05 +03:00
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
2
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 17:50:05 +03:00
2
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'x' identifier with the 'a' identifier in the a[b] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
3
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
4
2016-11-02 17:50:05 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
3
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
4
2016-11-02 17:50:05 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'y' identifier with the 'b' identifier in the a[b] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
},
{
"span": {
"replace": [
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
5
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
6
2016-11-02 17:50:05 +03:00
]
},
{
"start": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
5
2016-11-02 17:50:05 +03:00
],
"end": [
2016-12-02 00:03:52 +03:00
4,
2016-11-02 21:37:30 +03:00
6
2016-11-02 17:50:05 +03:00
]
}
]
},
2016-12-02 00:03:52 +03:00
"summary": "Replaced the 'z' identifier with the 'c' identifier in the a[b][c] subscript access of the 'main' function"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index 0e519e3..8b4c745 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-expressions.go",
2016-12-02 00:03:52 +03:00
"@@ -1,5 +1,5 @@",
" package main",
" ",
" func main() {",
2016-11-11 00:19:53 +03:00
"-x.y.z()",
2016-12-02 00:03:52 +03:00
"+a.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": "afd5153ab50147c234de8b3757736f30d7efe411..923206e8a0cd792702477ec1e1e7ab12bc3488c0"
2016-11-02 17:50:05 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-delete-insert-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-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-11 00:19:53 +03:00
8
]
}
2016-11-02 17:50:05 +03:00
},
2016-12-02 00:03:52 +03:00
"summary": "Deleted the 'a[b][c]()' function call in the main function of the 'main' module"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index 8b4c745..7905807 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-expressions.go",
2016-12-02 00:03:52 +03:00
"@@ -1,5 +1,5 @@",
" package main",
" ",
" func main() {",
2016-11-11 00:19:53 +03:00
"-a.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": "923206e8a0cd792702477ec1e1e7ab12bc3488c0..322dd4b61decf7a69223fa122f238e7001c5510d"
2016-11-02 17:50:05 +03:00
}
,{
2016-12-02 00:03:52 +03:00
"testCaseDescription": "go-selector-expressions-teardown-test",
2016-11-02 17:50:05 +03:00
"expectedResult": {
"changes": {
2016-11-02 21:37:30 +03:00
"selector-expressions.go": [
2016-11-02 17:50:05 +03:00
{
"span": {
"delete": {
"start": [
2016-11-11 00:19:53 +03:00
1,
2016-11-02 17:50:05 +03:00
1
],
"end": [
2016-12-02 00:03:52 +03:00
6,
1
2016-11-02 17:50:05 +03:00
]
}
},
2016-12-02 00:03:52 +03:00
"summary": "Deleted the 'main' module"
2016-11-02 17:50:05 +03:00
}
]
},
"errors": {}
},
"filePaths": [
2016-11-02 21:37:30 +03:00
"selector-expressions.go"
2016-11-02 17:50:05 +03:00
],
2016-11-11 00:19:53 +03:00
"patch": [
"diff --git a/selector-expressions.go b/selector-expressions.go",
2017-01-12 02:28:58 +03:00
"index 7905807..e69de29 100644",
2016-11-11 00:19:53 +03:00
"--- a/selector-expressions.go",
"+++ b/selector-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": "322dd4b61decf7a69223fa122f238e7001c5510d..eb22590bba5cac2db7b478012ad0ab6e980f7317"
2016-11-02 17:50:05 +03:00
}]