mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Fix spec which can fail if the pipe is closed before flushing in the subprocess
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60567 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
d51de2bd61
commit
1b17bd3e8f
1 changed files with 1 additions and 0 deletions
|
@ -23,6 +23,7 @@ describe "IO.popen" do
|
|||
it "raises IOError when writing a read-only pipe" do
|
||||
@io = IO.popen(ruby_cmd('puts "foo"'), "r")
|
||||
lambda { @io.write('foo') }.should raise_error(IOError)
|
||||
@io.read.should == "foo\n"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue