summaryrefslogtreecommitdiff
path: root/spec/functional/mixin
diff options
context:
space:
mode:
authorMatt Wrock <matt@mattwrock.com>2016-10-05 22:23:36 -0700
committerMatt Wrock <matt@mattwrock.com>2016-10-05 22:23:36 -0700
commit5517ddce30d5c84b01039db3d7a29e5fab8f9367 (patch)
tree53d2b84e57db03624cca4d02f60138f48935725b /spec/functional/mixin
parent9984b107e32cd5c4565c17e9ea8dd5bbe0da6bd7 (diff)
downloadchef-5517ddce30d5c84b01039db3d7a29e5fab8f9367.tar.gz
Revert Handling double quotes in powershell_out
Signed-off-by: Matt Wrock <matt@mattwrock.com>
Diffstat (limited to 'spec/functional/mixin')
-rw-r--r--spec/functional/mixin/powershell_out_spec.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/functional/mixin/powershell_out_spec.rb b/spec/functional/mixin/powershell_out_spec.rb
index 31bf397569..66214cb0c7 100644
--- a/spec/functional/mixin/powershell_out_spec.rb
+++ b/spec/functional/mixin/powershell_out_spec.rb
@@ -25,6 +25,10 @@ describe Chef::Mixin::PowershellOut, windows_only: true do
it "runs a powershell command and collects stdout" do
expect(powershell_out("get-process").run_command.stdout).to match /Handles\s+NPM\(K\)\s+PM\(K\)\s+WS\(K\)\s+VM\(M\)\s+CPU\(s\)\s+Id\s+/
end
+
+ it "does not raise exceptions when the command is invalid" do
+ powershell_out("this-is-not-a-valid-command").run_command
+ end
end
describe "#powershell_out!" do
@@ -33,7 +37,7 @@ describe Chef::Mixin::PowershellOut, windows_only: true do
end
it "raises exceptions when the command is invalid" do
- expect { powershell_out!("this-is-not-a-valid-command").run_command }.to raise_error(Mixlib::ShellOut::ShellCommandFailed)
+ expect { powershell_out!("this-is-not-a-valid-command").run_command }.to raise_exception(Mixlib::ShellOut::ShellCommandFailed)
end
end
end