diff options
author | Salim Alam <salam@chef.io> | 2015-08-28 12:00:21 -0700 |
---|---|---|
committer | Salim Alam <salam@chef.io> | 2015-08-28 12:00:21 -0700 |
commit | 4907ac708d7d6d782a1a71c564af422e87a81bc9 (patch) | |
tree | 10c16982bb1e736a57b8e2d2c6f3bfc0b81df888 | |
parent | 71925f0b253c0dd1b0943029d5399c3e20641ced (diff) | |
download | chef-4907ac708d7d6d782a1a71c564af422e87a81bc9.tar.gz |
More test fixes
-rw-r--r-- | spec/functional/dsl/reboot_pending_spec.rb | 6 | ||||
-rw-r--r-- | spec/functional/resource/registry_spec.rb | 5 | ||||
-rw-r--r-- | spec/functional/win32/registry_helper_spec.rb | 5 |
3 files changed, 13 insertions, 3 deletions
diff --git a/spec/functional/dsl/reboot_pending_spec.rb b/spec/functional/dsl/reboot_pending_spec.rb index 14dd9412d5..2cc98e241f 100644 --- a/spec/functional/dsl/reboot_pending_spec.rb +++ b/spec/functional/dsl/reboot_pending_spec.rb @@ -17,7 +17,11 @@ # require "chef/dsl/reboot_pending" -require "chef/win32/registry" + +if Chef::Platform::windows? + require "chef/win32/registry" +end + require "spec_helper" describe Chef::DSL::RebootPending, :windows_only do diff --git a/spec/functional/resource/registry_spec.rb b/spec/functional/resource/registry_spec.rb index f112ad9b00..9269574ba7 100644 --- a/spec/functional/resource/registry_spec.rb +++ b/spec/functional/resource/registry_spec.rb @@ -17,10 +17,13 @@ # limitations under the License. # -require "chef/win32/registry" require "chef/resource_reporter" require "spec_helper" +if Chef::Platform::windows? + require "chef/win32/registry" +end + describe Chef::Resource::RegistryKey, :unix_only do before(:all) do events = Chef::EventDispatch::Dispatcher.new diff --git a/spec/functional/win32/registry_helper_spec.rb b/spec/functional/win32/registry_helper_spec.rb index 9ef6fd006f..9f9763a22e 100644 --- a/spec/functional/win32/registry_helper_spec.rb +++ b/spec/functional/win32/registry_helper_spec.rb @@ -18,7 +18,10 @@ # require 'spec_helper' -require 'chef/win32/registry' + +if Chef::Platform::windows? + require 'chef/win32/registry' +end describe Chef::Resource::RegistryKey, :unix_only do before(:all) do |