diff options
author | danielsdeleo <dan@getchef.com> | 2015-05-13 19:20:32 -0700 |
---|---|---|
committer | danielsdeleo <dan@getchef.com> | 2015-05-20 15:13:57 -0700 |
commit | 68d6b10124b96012594d0a4fbe099eda738111b3 (patch) | |
tree | 3530dc61c41fb3203de925bdbd7ca798cdd246c6 /spec/support/shared/unit | |
parent | 1428270b0f2d0f2ae5d62ecb2aa512ffa7ac773e (diff) | |
download | chef-68d6b10124b96012594d0a4fbe099eda738111b3.tar.gz |
Stub `windows?` on ChefConfig so it applies to config
Diffstat (limited to 'spec/support/shared/unit')
-rw-r--r-- | spec/support/shared/unit/provider/file.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/support/shared/unit/provider/file.rb b/spec/support/shared/unit/provider/file.rb index 018be0a015..7de9698451 100644 --- a/spec/support/shared/unit/provider/file.rb +++ b/spec/support/shared/unit/provider/file.rb @@ -255,7 +255,7 @@ shared_examples_for Chef::Provider::File do context "examining file security metadata on Unix with a file that exists" do before do # fake that we're on unix even if we're on windows - allow(Chef::Platform).to receive(:windows?).and_return(false) + allow(ChefConfig).to receive(:windows?).and_return(false) # mock up the filesystem to behave like unix setup_normal_file stat_struct = double("::File.stat", :mode => 0600, :uid => 0, :gid => 0, :mtime => 10000) @@ -331,7 +331,7 @@ shared_examples_for Chef::Provider::File do context "examining file security metadata on Unix with a file that does not exist" do before do # fake that we're on unix even if we're on windows - allow(Chef::Platform).to receive(:windows?).and_return(false) + allow(ChefConfig).to receive(:windows?).and_return(false) setup_missing_file end @@ -380,7 +380,7 @@ shared_examples_for Chef::Provider::File do before do # fake that we're on unix even if we're on windows - allow(Chef::Platform).to receive(:windows?).and_return(false) + allow(ChefConfig).to receive(:windows?).and_return(false) # mock up the filesystem to behave like unix setup_normal_file stat_struct = double("::File.stat", :mode => 0600, :uid => 0, :gid => 0, :mtime => 10000) |