mirror of
https://github.com/github/semantic.git
synced 2024-12-23 14:54:16 +03:00
701 lines
22 KiB
JSON
701 lines
22 KiB
JSON
[{
|
|
"testCaseDescription": "go-float-literals-setup-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'main' module"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
3,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
2
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'main' function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index e69de29b..79058077 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -0,0 +1,5 @@",
|
|
"+package main",
|
|
"+",
|
|
"+func main() {",
|
|
"+",
|
|
"+}"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "cc715d4522917ba50c5e150c016f9175de100183..8e1f532e0aa5b7ac9f041ca3156f29dee401635e"
|
|
}
|
|
,{
|
|
"testCaseDescription": "go-float-literals-insert-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f5' assignment in the main function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index 79058077..772bdb09 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -1,5 +1,9 @@",
|
|
" package main",
|
|
" ",
|
|
" func main() {",
|
|
"-",
|
|
"+f1 = 1.5",
|
|
"+f2 = 1.5e100",
|
|
"+f3 = 1.5e+50",
|
|
"+f4 = 1.5e-5",
|
|
"+f5 = .5e-50",
|
|
" }"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "8e1f532e0aa5b7ac9f041ca3156f29dee401635e..2ff1f92e1b2b3281036cce1ea59f672edc77b131"
|
|
}
|
|
,{
|
|
"testCaseDescription": "go-float-literals-replacement-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f5' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f5' assignment in the main function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index 772bdb09..0818628b 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -1,9 +1,9 @@",
|
|
" package main",
|
|
" ",
|
|
" func main() {",
|
|
"-f1 = 1.5",
|
|
"-f2 = 1.5e100",
|
|
"-f3 = 1.5e+50",
|
|
"-f4 = 1.5e-5",
|
|
"-f5 = .5e-50",
|
|
"+f1 = 2.6",
|
|
"+f2 = 2.6e211",
|
|
"+f3 = 2.6e+60",
|
|
"+f4 = 2.6e-7",
|
|
"+f5 = .6e-60",
|
|
" }"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "2ff1f92e1b2b3281036cce1ea59f672edc77b131..3ef8e65dda8e49b53b187bc593d4f37e51b5e1ab"
|
|
}
|
|
,{
|
|
"testCaseDescription": "go-float-literals-delete-replacement-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'f5' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f5' assignment in the main function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index 0818628b..772bdb09 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -1,9 +1,9 @@",
|
|
" package main",
|
|
" ",
|
|
" func main() {",
|
|
"-f1 = 2.6",
|
|
"-f2 = 2.6e211",
|
|
"-f3 = 2.6e+60",
|
|
"-f4 = 2.6e-7",
|
|
"-f5 = .6e-60",
|
|
"+f1 = 1.5",
|
|
"+f2 = 1.5e100",
|
|
"+f3 = 1.5e+50",
|
|
"+f4 = 1.5e-5",
|
|
"+f5 = .5e-50",
|
|
" }"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "3ef8e65dda8e49b53b187bc593d4f37e51b5e1ab..bf49a908a46f46a657c215803a18240d24f0e933"
|
|
}
|
|
,{
|
|
"testCaseDescription": "go-float-literals-delete-insert-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
4,
|
|
1
|
|
],
|
|
"end": [
|
|
4,
|
|
9
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f1' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
5,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f2' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
6,
|
|
1
|
|
],
|
|
"end": [
|
|
6,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f3' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
7,
|
|
1
|
|
],
|
|
"end": [
|
|
7,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f4' assignment in the main function"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
8,
|
|
1
|
|
],
|
|
"end": [
|
|
8,
|
|
12
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'f5' assignment in the main function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index 772bdb09..79058077 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -1,9 +1,5 @@",
|
|
" package main",
|
|
" ",
|
|
" func main() {",
|
|
"-f1 = 1.5",
|
|
"-f2 = 1.5e100",
|
|
"-f3 = 1.5e+50",
|
|
"-f4 = 1.5e-5",
|
|
"-f5 = .5e-50",
|
|
"+",
|
|
" }"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "bf49a908a46f46a657c215803a18240d24f0e933..366544f9a84c8612205e7d35baac40d56e9ca4e4"
|
|
}
|
|
,{
|
|
"testCaseDescription": "go-float-literals-teardown-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"float-literals.go": [
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
13
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'main' module"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
3,
|
|
1
|
|
],
|
|
"end": [
|
|
5,
|
|
2
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'main' function"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"float-literals.go"
|
|
],
|
|
"patch": [
|
|
"diff --git a/float-literals.go b/float-literals.go",
|
|
"index 79058077..e69de29b 100644",
|
|
"--- a/float-literals.go",
|
|
"+++ b/float-literals.go",
|
|
"@@ -1,5 +0,0 @@",
|
|
"-package main",
|
|
"-",
|
|
"-func main() {",
|
|
"-",
|
|
"-}"
|
|
],
|
|
"gitDir": "test/corpus/repos/go",
|
|
"shas": "366544f9a84c8612205e7d35baac40d56e9ca4e4..a5301bd2ffecb1eb18b04a2bcafb091d297018c7"
|
|
}]
|