summaryrefslogtreecommitdiff
path: root/spec/unit/provider
diff options
context:
space:
mode:
authorMike Dodge <mikedodge04@fb.com>2015-04-01 13:35:03 -0700
committerMike Dodge <mikedodge04@fb.com>2015-04-01 13:35:03 -0700
commit455aaf2b879f341eea406b2004ff9524544da96e (patch)
tree8733dcdc986e8b0dcffcc4deb7c05e92e7ed542b /spec/unit/provider
parent04bd76a051270d529333c943e27fc2154378954f (diff)
downloadchef-455aaf2b879f341eea406b2004ff9524544da96e.tar.gz
adding assert for plist
Diffstat (limited to 'spec/unit/provider')
-rw-r--r--spec/unit/provider/service/macosx_spec.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/unit/provider/service/macosx_spec.rb b/spec/unit/provider/service/macosx_spec.rb
index 76301a8129..42d45f09e0 100644
--- a/spec/unit/provider/service/macosx_spec.rb
+++ b/spec/unit/provider/service/macosx_spec.rb
@@ -81,6 +81,7 @@ XML
with(/(#{su_cmd} '#{cmd}'|#{cmd})/).
and_return(double("Status",
:stdout => launchctl_stdout, :exitstatus => 0))
+ allow(File).to receive(:exists?).and_return([true], [])
allow(provider).to receive(:shell_out_with_systems_locale!).
with(/plutil -convert xml1 -o/).
and_return(double("Status", :stdout => plutil_stdout))
@@ -106,6 +107,7 @@ XML
before do
allow(Dir).to receive(:glob).and_return([])
+ allow(File).to receive(:exists?).and_return([true], [])
allow(provider).to receive(:shell_out!).
with(/plutil -convert xml1 -o/).
and_raise(Mixlib::ShellOut::ShellCommandFailed)