diff options
author | Bryan McLellan <btm@opscode.com> | 2012-01-25 18:29:28 -0800 |
---|---|---|
committer | Bryan McLellan <btm@opscode.com> | 2012-01-25 18:29:28 -0800 |
commit | 4cf4ae5331de3c52c789d4953262e0bd1c548751 (patch) | |
tree | c2f27cf5c0bbdaec5f3471ee707fb3007c9a2fe0 | |
parent | 6a49a0269c24ade8362e4687eae092622260aadc (diff) | |
download | chef-4cf4ae5331de3c52c789d4953262e0bd1c548751.tar.gz |
add alt_separator to windows platform mock
-rw-r--r-- | chef/spec/support/mock/platform.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/chef/spec/support/mock/platform.rb b/chef/spec/support/mock/platform.rb index 0717fb67af..78b704ea9b 100644 --- a/chef/spec/support/mock/platform.rb +++ b/chef/spec/support/mock/platform.rb @@ -10,8 +10,9 @@ def platform_mock(platform = :unix, &block) ENV['SYSTEMDRIVE'] = (platform == :windows ? 'C:' : nil) if block_given? mock_constants({"RUBY_PLATFORM" => (platform == :windows ? 'i386-mingw32' : 'x86_64-darwin11.2.0'), - "File::PATH_SEPARATOR" => (platform == :windows ? ';' : ":")}) do - yield + "File::PATH_SEPARATOR" => (platform == :windows ? ";" : ":"), + "File::ALT_SEPARATOR" => (platform == :windows ? "\\" : nil) }) do +yield end end end |