summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNimishaS <nimisha.sharad@msystechnologies.com>2016-10-10 07:03:51 +0000
committerNimishaS <nimisha.sharad@msystechnologies.com>2016-10-10 07:03:51 +0000
commitb2ae81e770255f935d0c75b3e0d7db1665609fd8 (patch)
tree08d216ea958424f813413dc49d32782d51f15120
parent08edf09ca4c8fbecf2585924719996ec71bb9d54 (diff)
downloadchef-b2ae81e770255f935d0c75b3e0d7db1665609fd8.tar.gz
Verifying powershell stdout in specs
Signed-off-by: NimishaS <nimisha.sharad@msystechnologies.com>
-rw-r--r--spec/unit/mixin/powershell_out_spec.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/unit/mixin/powershell_out_spec.rb b/spec/unit/mixin/powershell_out_spec.rb
index 6431aae018..4ecdcb8325 100644
--- a/spec/unit/mixin/powershell_out_spec.rb
+++ b/spec/unit/mixin/powershell_out_spec.rb
@@ -49,6 +49,7 @@ describe Chef::Mixin::PowershellOut, :windows_only do
it "passes if double quote is appended with single escape" do
result = object.powershell_out("Write-Verbose \"Some String\" -Verbose")
expect(result.stderr).to be == ""
+ expect(result.stdout).to be == "VERBOSE: Some String\n"
end
it "suppresses error if double quote is passed with double escape characters" do
@@ -82,6 +83,7 @@ describe Chef::Mixin::PowershellOut, :windows_only do
it "passes if double quote is appended with single escape" do
result = object.powershell_out!("Write-Verbose \"Some String\" -Verbose")
expect(result.stderr).to be == ""
+ expect(result.stdout).to be == "VERBOSE: Some String\n"
end
it "raises error if double quote is passed with double escape characters" do