2016-10-27 01:44:53 +03:00
|
|
|
[{
|
|
|
|
"testCaseDescription": "ruby-regex-insert-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '/^(foo|bar[^_])$/i' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index e69de29..02dce9d 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -0,0 +1 @@",
|
|
|
|
"+/^(foo|bar[^_])$/i"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "956b136e24f76c977fefd27d5368ecd527f721ec..49cb17b4244d627bd084dab1c7248c48a3cdb7cc"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-replacement-insert-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
6
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '%r/a/' regex"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
2,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
2,
|
|
|
|
10
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '%r<a<b>c>' regex"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
3,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
3,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '/^(foo|bar[^_])$/i' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index 02dce9d..c801d61 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1 +1,4 @@",
|
|
|
|
"+%r/a/",
|
|
|
|
"+%r<a<b>c>",
|
|
|
|
"+/^(foo|bar[^_])$/i",
|
|
|
|
" /^(foo|bar[^_])$/i"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "49cb17b4244d627bd084dab1c7248c48a3cdb7cc..a73a7605d28b1fe2b09ce87d8db7426ea6295610"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-delete-insert-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
6
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"summary": "Replaced the '%r/a/' regex with the '/^(foo|bar[^_])$/i' regex"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
2,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
2,
|
|
|
|
10
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '%r<a<b>c>' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index c801d61..42d4984 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1,4 +1,3 @@",
|
|
|
|
"-%r/a/",
|
|
|
|
"-%r<a<b>c>",
|
|
|
|
"+/^(foo|bar[^_])$/i",
|
|
|
|
" /^(foo|bar[^_])$/i",
|
|
|
|
" /^(foo|bar[^_])$/i"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "a73a7605d28b1fe2b09ce87d8db7426ea6295610..edcc26845e0ed493216f7b8ce1235e7a37ace55d"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-replacement-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"replace": [
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
6
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"summary": "Replaced the '/^(foo|bar[^_])$/i' regex with the '%r/a/' regex"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"insert": {
|
|
|
|
"start": [
|
|
|
|
2,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
2,
|
|
|
|
10
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Added the '%r<a<b>c>' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index 42d4984..c801d61 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1,3 +1,4 @@",
|
|
|
|
"-/^(foo|bar[^_])$/i",
|
|
|
|
"+%r/a/",
|
|
|
|
"+%r<a<b>c>",
|
|
|
|
" /^(foo|bar[^_])$/i",
|
|
|
|
" /^(foo|bar[^_])$/i"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "edcc26845e0ed493216f7b8ce1235e7a37ace55d..46655f4fd04784ed0fd995951c5f83018cc02d97"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-delete-replacement-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
4,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
4,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '/^(foo|bar[^_])$/i' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index c801d61..48e43a9 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1,4 +1,3 @@",
|
|
|
|
"+/^(foo|bar[^_])$/i",
|
|
|
|
" %r/a/",
|
|
|
|
" %r<a<b>c>",
|
|
|
|
"-/^(foo|bar[^_])$/i",
|
|
|
|
"-/^(foo|bar[^_])$/i"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "46655f4fd04784ed0fd995951c5f83018cc02d97..dd7c07f9f3797a03b8a34fbd1efdbc98b01d2e76"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-delete-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
19
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '/^(foo|bar[^_])$/i' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index 48e43a9..b23927a 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1,3 +1,2 @@",
|
|
|
|
"-/^(foo|bar[^_])$/i",
|
|
|
|
" %r/a/",
|
|
|
|
" %r<a<b>c>"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "dd7c07f9f3797a03b8a34fbd1efdbc98b01d2e76..a9ee657f847f069d80fe4f52e9b1fb3bf991f26f"
|
2016-10-27 01:44:53 +03:00
|
|
|
}
|
|
|
|
,{
|
|
|
|
"testCaseDescription": "ruby-regex-delete-rest-test",
|
|
|
|
"expectedResult": {
|
|
|
|
"changes": {
|
|
|
|
"regex.rb": [
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
1,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
1,
|
|
|
|
6
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '%r/a/' regex"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"span": {
|
|
|
|
"delete": {
|
|
|
|
"start": [
|
|
|
|
2,
|
|
|
|
1
|
|
|
|
],
|
|
|
|
"end": [
|
|
|
|
2,
|
|
|
|
10
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"summary": "Deleted the '%r<a<b>c>' regex"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"errors": {}
|
|
|
|
},
|
|
|
|
"filePaths": [
|
|
|
|
"regex.rb"
|
|
|
|
],
|
2016-11-04 01:41:59 +03:00
|
|
|
"patch": [
|
|
|
|
"diff --git a/regex.rb b/regex.rb",
|
|
|
|
"index b23927a..e69de29 100644",
|
|
|
|
"--- a/regex.rb",
|
|
|
|
"+++ b/regex.rb",
|
|
|
|
"@@ -1,2 +0,0 @@",
|
|
|
|
"-%r/a/",
|
|
|
|
"-%r<a<b>c>"
|
|
|
|
],
|
2016-10-27 01:44:53 +03:00
|
|
|
"gitDir": "test/corpus/repos/ruby",
|
2016-11-04 01:41:59 +03:00
|
|
|
"shas": "a9ee657f847f069d80fe4f52e9b1fb3bf991f26f..e8c4c9b4ba151237a0e88d5a650d34ee5a5a1b61"
|
2016-10-27 01:44:53 +03:00
|
|
|
}]
|