summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorHo-Sheng Hsiao <hosheng.hsiao@gmail.com>2012-03-26 14:44:01 -0400
committerHo-Sheng Hsiao <hosheng.hsiao@gmail.com>2012-03-26 14:44:01 -0400
commit724419d3d443ccf58075ef803b9aaf028ce2a4ee (patch)
tree8aceb5b3d10a47ca828abe060466d4c7cb424a8b /spec
parent7a3848055b98e55c5d4c4562202c16ada4dfbe03 (diff)
downloadmixlib-shellout-724419d3d443ccf58075ef803b9aaf028ce2a4ee.tar.gz
[CHEF-2994][STDIN] ShellOut#input should set the input option
Diffstat (limited to 'spec')
-rw-r--r--spec/mixlib/shellout/shellout_spec.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/mixlib/shellout/shellout_spec.rb b/spec/mixlib/shellout/shellout_spec.rb
index a8dcf5f..baf06d1 100644
--- a/spec/mixlib/shellout/shellout_spec.rb
+++ b/spec/mixlib/shellout/shellout_spec.rb
@@ -156,6 +156,16 @@ describe Mixlib::ShellOut do
should eql(value)
end
end
+
+ context 'when setting an input' do
+ let(:accessor) { :input }
+ let(:value) { "Random content #{rand(1000000)}" }
+ let(:stream) { StringIO.new }
+
+ it "should set the input" do
+ should eql(value)
+ end
+ end
end
context "with options hash" do