pipes should not flush write to read when not in sync mode
----------------------------------------------------------
Key: JRUBY-1892
URL: http://jira.codehaus.org/browse/JRUBY-1892
Project: JRuby
Issue Type: Sub-task
Reporter: Charles Oliver Nutter
Assignee: Thomas E Enebo
Fix For: JRuby 1.1
Error, after the select; the pipe isn't expected to be ready for read:
{noformat}
2) Failure:
test_flush(TestIO) [test/rubicon/test_io.rb:539]:
<nil> expected but was
<[[#<IO:0x18>], [], []]>.
{noformat}
Test:
{code}
def test_flush
unless WIN32
read, write = IO.pipe
write.sync = false
write.print "hello"
assert_nil(select([read], nil, [read], 0.1))
write.flush
assert_equal([[read],[],[]], select([read], nil, [read], 0.1))
read.close
write.close
end
end
{code}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email