aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-22 02:03:49 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-22 02:03:49 +0000
commitb09ff06845267dce70c8b7868a68ae88acd54af2 (patch)
tree41a5a3d2f082fc8a1e372ec6e75bcc822073433d /spec
parent199dc8e0db47be9da115b84bcf253b4429a39792 (diff)
downloadruby-b09ff06845267dce70c8b7868a68ae88acd54af2.tar.gz
Dir.glob with FNM_EXTGLOB is optimized [Feature #13873]
The order of resulted array is changed in some cases. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'spec')
-rw-r--r--spec/ruby/core/dir/shared/glob.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/core/dir/shared/glob.rb b/spec/ruby/core/dir/shared/glob.rb
index d2201cd6cd..11ace13326 100644
--- a/spec/ruby/core/dir/shared/glob.rb
+++ b/spec/ruby/core/dir/shared/glob.rb
@@ -221,12 +221,12 @@ describe :dir_glob, shared: true do
it "respects the order of {} expressions, expanding left most first" do
files = Dir.send(@method, "brace/a{.js,.html}{.erb,.rjs}")
- files.should == %w!brace/a.js.rjs brace/a.html.erb!
+ files.sort.should == %w!brace/a.html.erb brace/a.js.rjs!
end
it "respects the optional nested {} expressions" do
files = Dir.send(@method, "brace/a{.{js,html},}{.{erb,rjs},}")
- files.should == %w!brace/a.js.rjs brace/a.js brace/a.html.erb brace/a.erb brace/a!
+ files.sort.should == %w!brace/a brace/a.erb brace/a.html.erb brace/a.js brace/a.js.rjs!
end
it "matches special characters by escaping with a backslash with '\\<character>'" do