mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Merge branch 'textmate' of github.com:github/atom into textmate
This commit is contained in:
3
Rakefile
3
Rakefile
@@ -71,13 +71,12 @@ task :"copy-files-to-bundle" => :"verify-prerequisites" do
|
||||
sh "coffee -c -o #{dest}/src/stdlib src/stdlib/require.coffee"
|
||||
cp "src/stdlib/onig-reg-exp-extension.js", "#{dest}/src/stdlib"
|
||||
unless ENV['LOAD_RESOURCES_FROM_DIR']
|
||||
%w(src static vendor spec benchmark).each do |dir|
|
||||
%w(src static vendor spec benchmark bundles themes).each do |dir|
|
||||
rm_rf File.join(dest, dir)
|
||||
cp_r dir, File.join(dest, dir)
|
||||
end
|
||||
|
||||
sh "coffee -c #{dest}/src #{dest}/vendor #{dest}/spec #{dest}/benchmark"
|
||||
cp_r "bundles", "#{dest}/bundles"
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -15,12 +15,15 @@ describe "OnigRegExp", ->
|
||||
describe ".getCaptureTree(string, index)", ->
|
||||
it "returns match with nested capture groups organized into a tree", ->
|
||||
regex = new OnigRegExp("a((bc)d)e(f(g)(h))(?=ij)")
|
||||
tree = regex.getCaptureTree("abcdefghij")
|
||||
tree = regex.getCaptureIndices("abcdefghij")
|
||||
|
||||
expect(tree).toEqual [
|
||||
0, 0, 8
|
||||
[1, 1, 4, [2, 1, 3]],
|
||||
[3, 5, 8, [4, 6, 7], [5, 7, 8]]
|
||||
1, 1, 4,
|
||||
2, 1, 3,
|
||||
3, 5, 8,
|
||||
4, 6, 7,
|
||||
5, 7, 8
|
||||
]
|
||||
|
||||
it "returns undefined if there was no match", ->
|
||||
|
||||
Reference in New Issue
Block a user