From 1d49eb63c3612522ba4602e3640a7eb4c430f756 Mon Sep 17 00:00:00 2001 From: Justin Ko Date: Sat, 19 May 2012 20:12:13 -0600 Subject: [PATCH] Use File::ALT_SEPARATOR if it is not nil (it is on nix systems). --- lib/rspec/core/configuration.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/rspec/core/configuration.rb b/lib/rspec/core/configuration.rb index 25c996ce23..56393a31d4 100644 --- a/lib/rspec/core/configuration.rb +++ b/lib/rspec/core/configuration.rb @@ -806,7 +806,7 @@ def randomize? def get_files_to_run(paths) patterns = pattern.split(",") paths.map do |path| - path = path.gsub(File::ALT_SEPARATOR, File::SEPARATOR) + path = path.gsub(File::ALT_SEPARATOR, File::SEPARATOR) if File::ALT_SEPARATOR File.directory?(path) ? gather_directories(path, patterns) : extract_location(path) end.flatten end