2016-11-02 17:50:05 +03:00
|
|
|
[{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-setup-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-11-11 00:19:53 +03:00
|
|
|
1,
|
2016-12-02 00:03:52 +03:00
|
|
|
1
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"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": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index e69de29..6aaca9e 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -0,0 +1,5 @@",
|
|
|
|
"+package main",
|
|
|
|
"+",
|
2016-12-07 00:09:12 +03:00
|
|
|
"+func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
"+",
|
2016-12-07 00:09:12 +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-11 00:08:59 +03:00
|
|
|
"shas": "70869bde4ca394121b153f1a8c3d6ef3feff2406..f1b7450f741759a23f1ecb79eafd6aa2bd97e577"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-insert-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
7
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
18
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2017-01-11 00:08:59 +03:00
|
|
|
"summary": "Added the 'self Person' parameter declaration in the main module"
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
20
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
26
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the 'Equals' identifier in the main module"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
27
|
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
39
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2017-01-11 00:08:59 +03:00
|
|
|
"summary": "Added the 'other Person' parameter declaration in the main module"
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
41
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
45
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the 'bool' identifier in the main module"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
46
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
48
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '{}' block in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index 6aaca9e..e556c01 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"@@ -2,4 +2,4 @@ package main",
|
|
|
|
" ",
|
|
|
|
" func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
" ",
|
|
|
|
"-",
|
2016-12-07 00:09:12 +03:00
|
|
|
"+func (self Person) Equals(other Person) bool {}"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-11 00:08:59 +03:00
|
|
|
"shas": "f1b7450f741759a23f1ecb79eafd6aa2bd97e577..523aff8af1e95bff2211d2206b7d614416a05010"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-replacement-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-11-02 17:50:05 +03:00
|
|
|
12
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
18
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-11-02 17:50:05 +03:00
|
|
|
12
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
15
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-07 00:09:12 +03:00
|
|
|
"summary": "Replaced the 'Person' identifier with the 'Num' identifier in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
33
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
39
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
30
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
33
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-07 00:09:12 +03:00
|
|
|
"summary": "Replaced the 'Person' identifier with the 'Num' identifier in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index e556c01..1be6d20 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"@@ -2,4 +2,4 @@ package main",
|
|
|
|
" ",
|
|
|
|
" func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
" ",
|
|
|
|
"-func (self Person) Equals(other Person) bool {}",
|
2016-12-07 00:09:12 +03:00
|
|
|
"+func (self Num) Equals(other Num) bool {}"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-11 00:08:59 +03:00
|
|
|
"shas": "523aff8af1e95bff2211d2206b7d614416a05010..83edfb1736e50a32bce27448298a031c489ec773"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-delete-replacement-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-11-02 17:50:05 +03:00
|
|
|
12
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
15
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-11-02 17:50:05 +03:00
|
|
|
12
|
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
18
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-07 00:09:12 +03:00
|
|
|
"summary": "Replaced the 'Num' identifier with the 'Person' identifier in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
30
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
33
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
33
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
2016-12-02 00:03:52 +03:00
|
|
|
39
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2016-12-07 00:09:12 +03:00
|
|
|
"summary": "Replaced the 'Num' identifier with the 'Person' identifier in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index 1be6d20..e556c01 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"@@ -2,4 +2,4 @@ package main",
|
|
|
|
" ",
|
|
|
|
" func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
" ",
|
|
|
|
"-func (self Num) Equals(other Num) bool {}",
|
2016-12-07 00:09:12 +03:00
|
|
|
"+func (self Person) Equals(other Person) bool {}"
|
2016-11-11 00:19:53 +03:00
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"gitDir": "test/corpus/repos/go",
|
2017-01-11 00:08:59 +03:00
|
|
|
"shas": "83edfb1736e50a32bce27448298a031c489ec773..ce7af3c2dfabd69ff372fc05c7e7839097d48c46"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-delete-insert-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
7
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
18
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2017-01-11 00:08:59 +03:00
|
|
|
"summary": "Deleted the 'self Person' parameter declaration in the main module"
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
2016-11-02 17:50:05 +03:00
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
20
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
26
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the 'Equals' identifier in the main module"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
27
|
|
|
|
],
|
2016-11-02 17:50:05 +03:00
|
|
|
"end": [
|
2016-12-07 00:09:12 +03:00
|
|
|
5,
|
|
|
|
39
|
2016-11-02 17:50:05 +03:00
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2017-01-11 00:08:59 +03:00
|
|
|
"summary": "Deleted the 'other Person' parameter declaration in the main module"
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
41
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
45
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the 'bool' identifier in the main module"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
5,
|
|
|
|
46
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
5,
|
|
|
|
48
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '{}' block in the main module"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
]
|
2016-12-07 00:09:12 +03:00
|
|
|
},
|
|
|
|
"errors": {}
|
2016-11-02 17:50:05 +03:00
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index e556c01..6aaca9e 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"@@ -2,4 +2,4 @@ package main",
|
|
|
|
" ",
|
|
|
|
" func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
" ",
|
2016-11-11 00:19:53 +03:00
|
|
|
"-func (self Person) Equals(other Person) bool {}",
|
2016-12-07 00:09:12 +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-11 00:08:59 +03:00
|
|
|
"shas": "ce7af3c2dfabd69ff372fc05c7e7839097d48c46..f531f2f7d20da126818b26dae9df615581dd6f25"
|
2016-11-02 17:50:05 +03:00
|
|
|
}
|
|
|
|
,{
|
2016-12-02 00:03:52 +03:00
|
|
|
"testCaseDescription": "go-method-declarations-teardown-test",
|
2016-11-02 17:50:05 +03:00
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"method-declarations.go": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
2016-11-11 00:19:53 +03:00
|
|
|
1,
|
2016-12-02 00:03:52 +03:00
|
|
|
1
|
2016-11-02 17:50:05 +03:00
|
|
|
],
|
|
|
|
"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": [
|
|
|
|
"method-declarations.go"
|
|
|
|
],
|
2016-11-11 00:19:53 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/method-declarations.go b/method-declarations.go",
|
2016-12-07 00:09:12 +03:00
|
|
|
"index 6aaca9e..e69de29 100644",
|
2016-11-11 00:19:53 +03:00
|
|
|
"--- a/method-declarations.go",
|
|
|
|
"+++ b/method-declarations.go",
|
2016-12-02 00:03:52 +03:00
|
|
|
"@@ -1,5 +0,0 @@",
|
|
|
|
"-package main",
|
|
|
|
"-",
|
2016-12-07 00:09:12 +03:00
|
|
|
"-func main() {}",
|
2016-12-02 00:03:52 +03:00
|
|
|
"-",
|
2016-12-07 00:09:12 +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-11 00:08:59 +03:00
|
|
|
"shas": "f531f2f7d20da126818b26dae9df615581dd6f25..7e41a96d5cfb8d0e3975f95e6a6dbfe84123e1e5"
|
2016-11-02 17:50:05 +03:00
|
|
|
}]
|