1
1
mirror of https://github.com/github/semantic.git synced 2024-12-24 15:35:14 +03:00
semantic/test/corpus/diff-summaries/javascript/arrow-function.json

348 lines
11 KiB
JSON
Raw Normal View History

2016-10-11 18:12:20 +03:00
[{
"testCaseDescription": "javascript-arrow-function-insert-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"insert": {
2016-10-11 18:12:20 +03:00
"start": [
1,
1
],
"end": [
1,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Added an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index e69de29..9ef167c 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -0,0 +1 @@",
"+(f, g) => { return h; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "d700dc51fee7a3dd557906dcdf46d426285d7955..edda3c60ac532d534d84539648fa827ff18a6c59"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-replacement-insert-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"insert": {
2016-10-11 18:12:20 +03:00
"start": [
1,
1
],
"end": [
1,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Added an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
},
{
"span": {
2016-10-11 18:54:47 +03:00
"insert": {
2016-10-11 18:12:20 +03:00
"start": [
2,
1
],
"end": [
2,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Added an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index 9ef167c..92dea6f 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1 +1,3 @@",
"+(f, g) => { return g; };",
"+(f, g) => { return h; };",
" (f, g) => { return h; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "edda3c60ac532d534d84539648fa827ff18a6c59..63fd87f8cafc4a46f2927f9825cc20e5f116a093"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-delete-insert-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"replace": [
2016-10-11 18:12:20 +03:00
{
"start": [
1,
20
],
"end": [
1,
21
]
},
{
"start": [
1,
20
],
"end": [
1,
21
]
}
]
},
2016-10-11 23:17:34 +03:00
"summary": "Replaced the 'g' identifier with the 'h' identifier"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index 92dea6f..8f5bb51 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1,3 +1,3 @@",
"-(f, g) => { return g; };",
"+(f, g) => { return h; };",
" (f, g) => { return h; };",
" (f, g) => { return h; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "63fd87f8cafc4a46f2927f9825cc20e5f116a093..29b18be738dde19aa61343c5f4e54bf83f4b30ea"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-replacement-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"replace": [
2016-10-11 18:12:20 +03:00
{
"start": [
1,
20
],
"end": [
1,
21
]
},
{
"start": [
1,
20
],
"end": [
1,
21
]
}
]
},
2016-10-11 23:17:34 +03:00
"summary": "Replaced the 'h' identifier with the 'g' identifier"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index 8f5bb51..92dea6f 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1,3 +1,3 @@",
"-(f, g) => { return h; };",
"+(f, g) => { return g; };",
" (f, g) => { return h; };",
" (f, g) => { return h; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "29b18be738dde19aa61343c5f4e54bf83f4b30ea..d92f900ef9873f273da632ea9c54adcd7acc7961"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-delete-replacement-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"delete": {
2016-10-11 18:12:20 +03:00
"start": [
1,
1
],
"end": [
1,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Deleted an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
},
{
"span": {
2016-10-11 18:54:47 +03:00
"delete": {
2016-10-11 18:12:20 +03:00
"start": [
2,
1
],
"end": [
2,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Deleted an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
},
{
"span": {
2016-10-11 18:54:47 +03:00
"insert": {
2016-10-11 18:12:20 +03:00
"start": [
2,
1
],
"end": [
2,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Added an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index 92dea6f..acab9a9 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1,3 +1,2 @@",
"-(f, g) => { return g; };",
"-(f, g) => { return h; };",
" (f, g) => { return h; };",
"+(f, g) => { return g; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "d92f900ef9873f273da632ea9c54adcd7acc7961..243f2be7291992566bd0ab2c2caef9e7ac13e02d"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-delete-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"delete": {
2016-10-11 18:12:20 +03:00
"start": [
1,
1
],
"end": [
1,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Deleted an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index acab9a9..ef1be25 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1,2 +1 @@",
"-(f, g) => { return h; };",
" (f, g) => { return g; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "243f2be7291992566bd0ab2c2caef9e7ac13e02d..3128237c6d11459cf7d3e9add902e7be8d38710b"
2016-10-11 18:12:20 +03:00
}
,{
"testCaseDescription": "javascript-arrow-function-delete-rest-test",
"expectedResult": {
"changes": {
"arrow-function.js": [
{
"span": {
2016-10-11 18:54:47 +03:00
"delete": {
2016-10-11 18:12:20 +03:00
"start": [
1,
1
],
"end": [
1,
24
]
}
},
2016-10-11 23:17:34 +03:00
"summary": "Deleted an anonymous(f, g) function"
2016-10-11 18:12:20 +03:00
}
]
},
"errors": {}
},
"filePaths": [
"arrow-function.js"
],
"patch": [
"diff --git a/arrow-function.js b/arrow-function.js",
"index ef1be25..e69de29 100644",
"--- a/arrow-function.js",
"+++ b/arrow-function.js",
"@@ -1 +0,0 @@",
"-(f, g) => { return g; };"
],
2016-10-11 18:12:20 +03:00
"gitDir": "test/corpus/repos/javascript",
"shas": "3128237c6d11459cf7d3e9add902e7be8d38710b..5cab8720cde055f6d78f5c5deaf8980b89a434e1"
2016-10-11 18:12:20 +03:00
}]