mirror of
https://github.com/github/semantic.git
synced 2024-12-23 23:11:50 +03:00
348 lines
11 KiB
JSON
348 lines
11 KiB
JSON
[{
|
|
"testCaseDescription": "javascript-throw-statement-insert-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
26
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'new Error(\"uh oh\")' throw statement"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index e69de29..e2fcb67 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -0,0 +1 @@",
|
|
"+throw new Error(\"uh oh\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "8e3f45940f773e7849a53fefdaeb52a682a6a488..116eb17be5e023970df37ba38884c86aa4cb9dbd"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-replacement-insert-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
29
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'new Error(\"oooooops\")' throw statement"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
2,
|
|
1
|
|
],
|
|
"end": [
|
|
2,
|
|
26
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'new Error(\"uh oh\")' throw statement"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index e2fcb67..c0020c8 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1 +1,3 @@",
|
|
"+throw new Error(\"oooooops\");",
|
|
"+throw new Error(\"uh oh\");",
|
|
" throw new Error(\"uh oh\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "116eb17be5e023970df37ba38884c86aa4cb9dbd..e1a31ba713d3185c274f86dd4e8644740fb7429d"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-delete-insert-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"replace": [
|
|
{
|
|
"start": [
|
|
1,
|
|
17
|
|
],
|
|
"end": [
|
|
1,
|
|
27
|
|
]
|
|
},
|
|
{
|
|
"start": [
|
|
1,
|
|
17
|
|
],
|
|
"end": [
|
|
1,
|
|
24
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"summary": "Replaced the \"oooooops\" string with the \"uh oh\" string in the Error(\"uh oh\") function call"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index c0020c8..4644233 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1,3 +1,3 @@",
|
|
"-throw new Error(\"oooooops\");",
|
|
"+throw new Error(\"uh oh\");",
|
|
" throw new Error(\"uh oh\");",
|
|
" throw new Error(\"uh oh\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "e1a31ba713d3185c274f86dd4e8644740fb7429d..dad40ac44ee1763621da95939261c0afc7664ec4"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-replacement-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"replace": [
|
|
{
|
|
"start": [
|
|
1,
|
|
17
|
|
],
|
|
"end": [
|
|
1,
|
|
24
|
|
]
|
|
},
|
|
{
|
|
"start": [
|
|
1,
|
|
17
|
|
],
|
|
"end": [
|
|
1,
|
|
27
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"summary": "Replaced the \"uh oh\" string with the \"oooooops\" string in the Error(\"oooooops\") function call"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index 4644233..c0020c8 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1,3 +1,3 @@",
|
|
"-throw new Error(\"uh oh\");",
|
|
"+throw new Error(\"oooooops\");",
|
|
" throw new Error(\"uh oh\");",
|
|
" throw new Error(\"uh oh\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "dad40ac44ee1763621da95939261c0afc7664ec4..6ead807809e97520b2dce628bc592bfa358dd249"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-delete-replacement-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
29
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'new Error(\"oooooops\")' throw statement"
|
|
},
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
2,
|
|
1
|
|
],
|
|
"end": [
|
|
2,
|
|
26
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'new Error(\"uh oh\")' throw statement"
|
|
},
|
|
{
|
|
"span": {
|
|
"insert": {
|
|
"start": [
|
|
2,
|
|
1
|
|
],
|
|
"end": [
|
|
2,
|
|
29
|
|
]
|
|
}
|
|
},
|
|
"summary": "Added the 'new Error(\"oooooops\")' throw statement"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index c0020c8..a1bbf3e 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1,3 +1,2 @@",
|
|
"-throw new Error(\"oooooops\");",
|
|
"-throw new Error(\"uh oh\");",
|
|
" throw new Error(\"uh oh\");",
|
|
"+throw new Error(\"oooooops\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "6ead807809e97520b2dce628bc592bfa358dd249..c1804715b17f4c02c529052b13f67eab4f85d127"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-delete-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
26
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'new Error(\"uh oh\")' throw statement"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index a1bbf3e..cc3c531 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1,2 +1 @@",
|
|
"-throw new Error(\"uh oh\");",
|
|
" throw new Error(\"oooooops\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "c1804715b17f4c02c529052b13f67eab4f85d127..36892466e1b20aa85270c797d4898149a5456dae"
|
|
}
|
|
,{
|
|
"testCaseDescription": "javascript-throw-statement-delete-rest-test",
|
|
"expectedResult": {
|
|
"changes": {
|
|
"throw-statement.js": [
|
|
{
|
|
"span": {
|
|
"delete": {
|
|
"start": [
|
|
1,
|
|
1
|
|
],
|
|
"end": [
|
|
1,
|
|
29
|
|
]
|
|
}
|
|
},
|
|
"summary": "Deleted the 'new Error(\"oooooops\")' throw statement"
|
|
}
|
|
]
|
|
},
|
|
"errors": {}
|
|
},
|
|
"filePaths": [
|
|
"throw-statement.js"
|
|
],
|
|
"patch": [
|
|
"diff --git a/throw-statement.js b/throw-statement.js",
|
|
"index cc3c531..e69de29 100644",
|
|
"--- a/throw-statement.js",
|
|
"+++ b/throw-statement.js",
|
|
"@@ -1 +0,0 @@",
|
|
"-throw new Error(\"oooooops\");"
|
|
],
|
|
"gitDir": "test/corpus/repos/javascript",
|
|
"shas": "36892466e1b20aa85270c797d4898149a5456dae..a5583b5ba5ae300bddff029cb144c539a2cb48fd"
|
|
}]
|