diff options
author | Tim Smith <tsmith@chef.io> | 2018-02-15 11:55:40 -0800 |
---|---|---|
committer | Bryan McLellan <btm@loftninjas.org> | 2018-03-27 14:00:13 -0400 |
commit | 2a51d02692b864d852cd2a3d5160b799476f03c3 (patch) | |
tree | 294d3cfbe0e7ce2dfe60babee6261c82ff171ed5 | |
parent | f5c93b5f69ea11788fd8d0c259e5456cfb7681a0 (diff) | |
download | ohai-2a51d02692b864d852cd2a3d5160b799476f03c3.tar.gz |
Fix vmware specs to actually run the plugin
It helps to run the plugin before we make sure the attributes aren't there.
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | spec/unit/plugins/vmware_spec.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/unit/plugins/vmware_spec.rb b/spec/unit/plugins/vmware_spec.rb index 7ea04619..e568fd44 100644 --- a/spec/unit/plugins/vmware_spec.rb +++ b/spec/unit/plugins/vmware_spec.rb @@ -64,6 +64,7 @@ describe Ohai::System, "plugin vmware" do plugin[:virtualization][:systems] = Mash.new plugin[:virtualization][:systems][:vmware] = Mash.new allow(File).to receive(:exist?).with("/usr/bin/vmware-toolbox-cmd").and_return(false) + plugin.run expect(plugin).not_to have_key(:vmware) end end @@ -73,6 +74,7 @@ describe Ohai::System, "plugin vmware" do plugin[:virtualization] = Mash.new plugin[:virtualization][:systems] = Mash.new plugin[:virtualization][:systems][:vbox] = Mash.new + plugin.run expect(plugin).not_to have_key(:vmware) end end |